# AI＋従来ソフト協調論

CURRENT_STATUS: UNKNOWN
OBSERVATION: SPEC_ONLY
FRESHNESS: UNKNOWN
PAGE_TYPE: reference
CANONICAL_URL: /tools/ea-038-ai
CLAIM_IDS: none
EVIDENCE_IDS: EVD-EA-038-URL-E2906621865C, EVD-EA-038-URL-1489663B6F37, EVD-EA-038-URL-0F32B54F0BCC, EVD-EA-038-URL-FC8C14D053CD, EVD-EA-038-URL-02D619BBEC9F, EVD-EA-038-URL-DD8D837248E1, EA-038-R11-RESEARCH, EA-038-R11-WEB-READBACK
UNKNOWN_IDS: EA-038-UNKNOWN-01, EA-038-UNKNOWN-CURRENTNESS
OPS_IDS: none

## Summary
AIにすべてを実行させず、意味解釈や計画をAIへ、厳密な計算・検証・検索・状態更新を従来ソフトへ返す。従来ソフトも正しさを自動保証しないため、型付き入力、権限、transaction/lock、idempotency、postcondition、readbackを実行契約として固定し、AIの成功宣言ではなく実システムからの再取得で閉じる。

## Current judgment
semantic decision planeとdeterministic execution/state planeを分離する。算術・集計・厳密pattern/schema validation・SQL query/update・transaction/locking・date arithmetic・formula・既知API操作はsoftware候補。AIは自然言語→typed intent、曖昧性検出、候補生成、例外説明を担う。成功宣言ではなくDB/API/file等のreadbackで閉じる。

## Scope
Enterprise AI Core / implementation / interoperability / non-LLM component / governance / operability.

## Confirmed
- semantic decision planeとdeterministic execution/state planeを分離する。算術・集計・厳密pattern/schema validation・SQL query/update・transaction/locking・date arithmetic・formula・既知API操作はsoftware候補。AIは自然言語→typed intent、曖昧性検出、候補生成、例外説明を担う。成功宣言ではなくDB/API/file等のreadbackで閉じる。

## UNKNOWN
- EA-038-UNKNOWN-01: / STOP_CONDITION
業務横断の一律routing threshold、distributed side effectsのatomicity、provider/tool横断exactly-onceは確定しない。境界原則、execution contract、failure envelope、evaluation profileまでboundedに確立したためEA-038停止。


RUN SUMMARY
COMPLETED_EA: EA-038
- EA-038-UNKNOWN-CURRENTNESS: 外部根拠の再確認日がcanonical body/control-planeで確定していないため、currentnessはUNKNOWNとして保持する。日付を推測補完しない。

## Evidence
- EVD-EA-038-URL-E2906621865C (RESEARCH): 1. PostgreSQL 18 Transactions | — https://www.postgresql.org/docs/18/tutorial-transactions.html
- EVD-EA-038-URL-1489663B6F37 (RESEARCH): 2. PostgreSQL 18 Client Connection Defaults | — https://www.postgresql.org/docs/18/runtime-config-client.html
- EVD-EA-038-URL-0F32B54F0BCC (RESEARCH): 3. SQLite Transaction | — https://www.sqlite.org/lang_transaction.html
- EVD-EA-038-URL-FC8C14D053CD (RESEARCH): 4. SQLite Atomic Commit | — https://www.sqlite.org/atomiccommit.html
- EVD-EA-038-URL-02D619BBEC9F (RESEARCH): 5. Python 3.14.7 re docs | — https://docs.python.org/3/library/re.html
- EVD-EA-038-URL-DD8D837248E1 (RESEARCH): 6. Google Apps Script Lock Service | — https://developers.google.com/apps-script/reference/lock
- EA-038-R11-RESEARCH (RESEARCH): EA-038 監査済みresearch / canonical revision binding
- EA-038-R11-WEB-READBACK (IMPL): EA-038 Web body identity / canonical readback

## Failure / limits
deterministic software≠correct software。transaction commit≠DB外side effectを含むend-to-end成功。DBごとにisolation/locking semanticsは異なる。regex match≠semantic correctness。Apps Script LockService≠distributed transaction。code generation成功≠execution/postcondition成功。AIのtool choiceが誤ればexecutorは誤操作を忠実に実行し得る。
## Practice
runtime/version、DB engine/isolation/config、Excel/Sheets surface、Apps Script authorization/quota、API entitlement、region、organization policy、credential scopeを個別確認。public docsをtenant実挙動へ外挿しない。
## Practice
PROPOSAL AI_SOFTWARE_EXECUTION_CONTRACT_V1 = operation_id,intent,component+version,typed_input,preconditions,authority,side_effect_class,idempotency_key,transaction_or_lock,timeout,retry,dry_run,expected_postcondition,result,readback,rollback_or_compensation,audit_ref,human_gate,UNKNOWN。
## Practice
HYBRID_EXECUTION_REGRESSION_V1。LLM-only / AI→software / deterministic-only baselineを比較し、exact accuracy、schema validity、side-effect correctness、duplicate execution、rollback/compensation、readback mismatch、latency、cost、human intervention、wrong-tool routingを測る。競合更新・retry・idempotency・lock timeoutもfixture化。
## Practice
executor credentialをleast privilegeで分離しsecretを不要にAIへ渡さない。generated SQL/codeは可能な範囲でallowlist/schema/static check/dry-run。read/write/irreversibleでapproval gateを分け、input/tool version/query hash/result/readback/actor classを監査。
## Practice
Enterprise AI Coreのtool/action execution、transaction/readback、least privilege、human approvalへ接続。EA-039では推論、semantic routing、deterministic executor、state store、validator、audit/readbackを別componentとして比較する。
## Practice
EA-400以降・本編正本・S063 Frozen TOC未変更

---
## Practice
AI_SOFTWARE_EXECUTION_CONTRACT_V1 remains DICTIONARY PROPOSAL. Transaction/lock primitives are not end-to-end exactly-once external-side-effect assurance. Preserve every OPEN_UNKNOWN from the authority packet.
TESTS: exact authority range readback PASS; proposal/UNKNOWN/transaction-boundary markers PASS. Build/CI deferred to eligible Git batch.
## WHY_THIS_MATTERS_TO_UPDATE
AIに決定論的処理まで模倣させず、意味解釈・計画と、Python/SQL/Excel/GAS/検索/正規表現/DB等の実行・状態管理を分離する。

## SCOPE_ROUTING
Enterprise AI Core / implementation / interoperability / non-LLM component / governance / operability.

## CLAIM_OR_RESEARCH_QUESTION
AI→従来ソフトhandoffで型、権限、transaction、idempotency、postcondition、readbackをどう契約化するか。

## EVIDENCE TABLE
1. PostgreSQL 18 Transactions | https://www.postgresql.org/docs/18/tutorial-transactions.html | current 18 docs, accessed 2026-09-25 | all-or-nothing transaction/intermediate-state isolation | VERIFIED_SPEC | support.
2. PostgreSQL 18 Client Connection Defaults | https://www.postgresql.org/docs/18/runtime-config-client.html | accessed 2026-09-25 | default isolation=Read Committed、semanticsは設定依存 | VERIFIED_SPEC | limit/context.
3. SQLite Transaction | https://www.sqlite.org/lang_transaction.html | accessed 2026-09-25 | explicit/implicit transaction、COMMIT/ROLLBACK、single simultaneous write | VERIFIED_SPEC | support/limit.
4. SQLite Atomic Commit | https://www.sqlite.org/atomiccommit.html | accessed 2026-09-25 | rollback modeでatomic commit、適用範囲を限定 | VERIFIED_SPEC | support/limit.
5. Python 3.14.7 re docs | https://docs.python.org/3/library/re.html | accessed 2026-09-25 | explicit pattern API/PatternError | VERIFIED_SPEC | context.
6. Google Apps Script Lock Service | https://developers.google.com/apps-script/reference/lock | accessed 2026-09-25 | shared-resource collision防止mutex、document/script/user locks | VERIFIED_SPEC + PRODUCT_VOLATILE | support/context.

## FINDINGS
semantic decision planeとdeterministic execution/state planeを分離する。算術・集計・厳密pattern/schema validation・SQL query/update・transaction/locking・date arithmetic・formula・既知API操作はsoftware候補。AIは自然言語→typed intent、曖昧性検出、候補生成、例外説明を担う。成功宣言ではなくDB/API/file等のreadbackで閉じる。

## LIMITS / COUNTEREVIDENCE / FAILURE ENVELOPE
deterministic software≠correct software。transaction commit≠DB外side effectを含むend-to-end成功。DBごとにisolation/locking semanticsは異なる。regex match≠semantic correctness。Apps Script LockService≠distributed transaction。code generation成功≠execution/postcondition成功。AIのtool choiceが誤ればexecutorは誤操作を忠実に実行し得る。

## AVAILABILITY_GATES
runtime/version、DB engine/isolation/config、Excel/Sheets surface、Apps Script authorization/quota、API entitlement、region、organization policy、credential scopeを個別確認。public docsをtenant実挙動へ外挿しない。

## IMPLEMENTATION_STATE
PROPOSAL AI_SOFTWARE_EXECUTION_CONTRACT_V1 = operation_id,intent,component+version,typed_input,preconditions,authority,side_effect_class,idempotency_key,transaction_or_lock,timeout,retry,dry_run,expected_postcondition,result,readback,rollback_or_compensation,audit_ref,human_gate,UNKNOWN。

## BENCHMARK_OR_EVAL
HYBRID_EXECUTION_REGRESSION_V1。LLM-only / AI→software / deterministic-only baselineを比較し、exact accuracy、schema validity、side-effect correctness、duplicate execution、rollback/compensation、readback mismatch、latency、cost、human intervention、wrong-tool routingを測る。競合更新・retry・idempotency・lock timeoutもfixture化。

## SECURITY / PRIVACY / AUDIT / COST / OPERABILITY
executor credentialをleast privilegeで分離しsecretを不要にAIへ渡さない。generated SQL/codeは可能な範囲でallowlist/schema/static check/dry-run。read/write/irreversibleでapproval gateを分け、input/tool version/query hash/result/readback/actor classを監査。

## SAFE_WORDING_FOR_FUTURE_BOOK
AIにすべてを実行させず、意味解釈や計画をAIへ、厳密な計算・検証・検索・状態更新を従来ソフトへ返す。従来ソフトも正しさを自動保証しないため、型付き入力、権限、transaction/lock、idempotency、postcondition、readbackを実行契約として固定し、AIの成功宣言ではなく実システムからの再取得で閉じる。

## UPDATE_WORK_HANDOFF
Enterprise AI Coreのtool/action execution、transaction/readback、least privilege、human approvalへ接続。EA-039では推論、semantic routing、deterministic executor、state store、validator、audit/readbackを別componentとして比較する。

## OPEN_UNKNOWN
/ STOP_CONDITION
業務横断の一律routing threshold、distributed side effectsのatomicity、provider/tool横断exactly-onceは確定しない。境界原則、execution contract、failure envelope、evaluation profileまでboundedに確立したためEA-038停止。


RUN SUMMARY
COMPLETED_EA: EA-038

## BOUNDARY
EA-400以降・本編正本・S063 Frozen TOC未変更

---

## AUDITED_BOUNDARY
AI_SOFTWARE_EXECUTION_CONTRACT_V1 remains DICTIONARY PROPOSAL. Transaction/lock primitives are not end-to-end exactly-once external-side-effect assurance. Preserve every OPEN_UNKNOWN from the authority packet.
TESTS: exact authority range readback PASS; proposal/UNKNOWN/transaction-boundary markers PASS. Build/CI deferred to eligible Git batch.

NEXT: /agent/start.json
STOP: This is a knowledge projection, not an execution order.