# Platform Independence

> A design rule that portable layers reach the operating system and vendor services only through abstractions.

Record: `architecture:platform-independence`
Kind: principle
Layer: [Resource Core](https://banes-lab.com/records/layer/resource-core.md)
Severity: contextual
Scope: application, runtime
Canonical: https://banes-lab.com/ontology#architecture-platform-independence

Listed in [Architecture principles](https://banes-lab.com/api/records/architecture.md), after [Portability](https://banes-lab.com/records/architecture/portability.md) and before [Environment Parity](https://banes-lab.com/records/architecture/environment-parity.md).

## Repair

- Refactored by: Abstract Platform API, Normalize Paths
- Detected by: OS-specific paths/APIs in portable layers
- Violated by: hardcoded platform assumptions
- Measured by: cross-platform test pass rate
- Enforced by: cross-platform CI

## Requires

- [Platform Abstraction](https://banes-lab.com/records/lexicon/platform-abstraction.md)

## Reinforces

- [Portability](https://banes-lab.com/records/architecture/portability.md)

## Enables

- [Cross-Platform Deployment](https://banes-lab.com/records/lexicon/cross-platform-deployment.md)

## Conflicts with

- [OS/Vendor Lock-In](https://banes-lab.com/records/lexicon/os-vendor-lock-in.md)

## In tension with

- [Native Optimization](https://banes-lab.com/records/lexicon/native-optimization.md)

## Tensions

- [Platform Independence / Native Optimization](https://banes-lab.com/records/tension/native-optimization-platform-independence.md)

## Severity

- [contextual](https://banes-lab.com/records/vocabulary/severity-contextual.md)

## Category

- [Portability / Infrastructure / Deployment](https://banes-lab.com/records/architecture-category/portability-infrastructure-deployment.md)

## Enforced by

- [rules/eslint/strings-harness-neutral.eslint.rule.ts](https://banes-lab.com/source/governance/rules/eslint/strings-harness-neutral.eslint.rule.ts.md)
- [runtime/entrypoints/coordination.entrypoint.ts](https://banes-lab.com/source/build/runtime/entrypoints/coordination.entrypoint.ts.md)

## Linked from

- [The behavior document](https://banes-lab.com/disciplined-methodology/start/the-behavior-document.md)
- [The drop-in](https://banes-lab.com/disciplined-methodology/start/onboarding.md)
- [Portability / Infrastructure / Deployment](https://banes-lab.com/ontology/principles/architecture-category-portability-infrastructure-deployment.md)
- [Portability / Infrastructure / Deployment](https://banes-lab.com/ontology/lexicon/lexicon-category-portability-infrastructure-deployment.md)
- [Severity levels](https://banes-lab.com/ontology/schema/the-vocabulary-severity.md)
- [The resolutions](https://banes-lab.com/ontology/schema/the-resolutions.md)
