Agmente / AppServerClient
AGENTS.md545 starsChanged 9 months agoMITView on GitHub
Maintenance guardrails: - Do not reintroduce unconditional thread/resume during reconnect. - Do not immediately issue another resume after successful listener+read attach. - Keep includeTurns: true on read-based hydration paths. - Remember that persistExtendedHistory is not backfilled for old sessions. See AppServerClient/codex-thread-hydration.md for the expanded maintenance checklist and regression scenarios.
Where files are headingNew AGENTS.md files have more rules about keeping secrets out of the code, and fewer about code style.
Of the AGENTS.md files we read, the 32,671 first seen in the last six months, against the older ones: the kind of rule that gained most share, and the kind that lost most. About files like this in general, not this one, and an estimate, since a kind is a pattern in the words.
In this repository13 other files it gives its agents.
- ACPClient/AGENTS.mdAGENTS.md
- Agents.mdAGENTS.md
- Agmente/AGENTS.mdAGENTS.md
- AgmenteTests/AGENTS.mdAGENTS.md
- AgmenteUITests/AGENTS.mdAGENTS.md
- e2e/AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- acp-local-runnerSkill
- codex-local-cli-e2eSkill
- repeat-with-delaySkill
- upstream-protocol-drift-watchSkill
- run-agmente-codex-e2eSkill
- run-agmente-e2eSkill
The file
Show its rules and text
We split this AGENTS.md into the rules it gives an agent
18 rules. About 0 are common, 12 are distinctive, and 6 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈12
Distinctive · estimate
This author's own choices. Worth a look.
6
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 7
Read .agmente.paths (from repo root) before cross-checking Codex app-server upstream source.
- Very specific: line 16
Default wire mode omits "jsonrpc":"2.0" header, with optional inclusion toggle.
- Distinctive: line 18
Keep event parser mappings aligned with upstream app-server method names.
- Distinctive: line 19
Treat method-name and payload-shape drift as compatibility-sensitive changes.
- Very specific: line 26
if loaded: addConversationListener + thread/read(includeTurns: true)
- Distinctive: line 28
use when thread is not loaded, or listener attach/read path is unavailable
- Distinctive: line 32
avoid duplicate assistant rows via normalized content + tool-call identity checks
- Very specific: line 37
Do not reintroduce unconditional thread/resume during reconnect.
- Distinctive: line 38
Do not immediately issue another resume after successful listener+read attach.
- Very specific: line 39
Keep includeTurns: true on read-based hydration paths.
- Distinctive: line 45
When adding app-server method support:
- Distinctive: line 46
Add method name constant.
- Distinctive: line 47
Add payload model and params encoder.
- Distinctive: line 48
Add typed service wrapper.
- Distinctive: line 49
Add response parser coverage if result is typed.
- Distinctive: line 50
Add or update event parser mapping if notifications/requests are involved.
- Distinctive: line 51
Add package tests for request flow, parse flow, and error handling.
- Very specific: line 54
Run package tests for AppServerClient.
≈ “Common” is an estimate: at least 1 in 5 of the 41,581 AGENTS.md files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
AppServerClient Package Guide
Scope
Typed Codex app-server transport/service package used by the iOS app.
External Repo Paths
- Read
.agmente.paths(from repo root) before cross-checking Codex app-server upstream source. - Codex upstream reference root:
AGMENTE_CODEX_REPO/codex-rs.
Architecture Model
- Transport and request orchestration are separated from protocol payload parsing.
- Service APIs should remain typed and avoid leaking raw JSON-RPC details to callers.
- Event parsing should map wire notifications/requests into stable app-facing event types.
Protocol Notes
- Default wire mode omits
"jsonrpc":"2.0"header, with optional inclusion toggle. - Handle both notifications and server-initiated requests (for approvals and similar flows).
- Keep event parser mappings aligned with upstream app-server method names.
- Treat method-name and payload-shape drift as compatibility-sensitive changes.
Codex Thread Maintenance
Final thread hydration behavior used by Agmente for Codex:
- Open/reconnect prefers non-destructive attach:
thread/loaded/list- if loaded:
addConversationListener+thread/read(includeTurns: true)
thread/resumeis fallback only:- use when thread is not loaded, or listener attach/read path is unavailable
- Merge behavior:
- preserve richer local tool-call rows/outputs
- append newly resumed items
- avoid duplicate assistant rows via normalized content + tool-call identity checks
- Persistence for cold relaunch:
- send
persistExtendedHistory: trueonthread/startandthread/resume
- send
Maintenance guardrails:
- Do not reintroduce unconditional
thread/resumeduring reconnect. - Do not immediately issue another resume after successful listener+read attach.
- Keep
includeTurns: trueon read-based hydration paths. - Remember that
persistExtendedHistoryis not backfilled for old sessions.
See AppServerClient/codex-thread-hydration.md for the expanded maintenance checklist and regression scenarios.
Extension Pattern
When adding app-server method support:
- Add method name constant.
- Add payload model and params encoder.
- Add typed service wrapper.
- Add response parser coverage if result is typed.
- Add or update event parser mapping if notifications/requests are involved.
- Add package tests for request flow, parse flow, and error handling.
Tests
- Run package tests for
AppServerClient.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

