lat-code

A controlled worker for carrying out one approved coding task recorded in a LAT task ledger. It records the task's progress and result while preserving the task history.

In plain words
What is it for?
Use it to execute one specified implementation task, update its running and final status, save the result, and stop after that task is complete.
Why use it?
It prevents an automated worker from accidentally taking unrelated tasks or repeating completed work. The ledger provides a trace of what was approved, running, and finished.

Skill for Claude CodeCodex

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/ouob-tw/loopagentteams/lat-code
Any agent
npx skills add ouob-tw/LoopAgentTeams --skill lat-code
Clone the repo
git clone --depth 1 https://github.com/ouob-tw/LoopAgentTeams

Made for: Claude Code, Codex.

Per session 66 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,300 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00066 $0.01300
Opus 5 $0.00033 $0.00650
Sonnet 5 $0.00013 $0.00260
Haiku 4.5 $0.00007 $0.00130

Measured 2d ago against content hash 84903f8862aa, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

lat-code scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

lat-code/SKILL.md · 69 lines

How it starts

The opening of the file, as written. The whole thing — 69 lines — stays where its author put it; the contents beside it link to each section on GitHub.

LAT Code

執行 .lat/workspace/<TASK_ID>/tasks.yaml 中一筆精確匹配 agent_idcode_executor_<instance>_<task_id>)的已核准 code phase 實作任務,通常由 lat-dispatch 啟動。

執行邊界

  • 僅執行已核准的實作任務。不處理規格審查或計劃審查。
  • 一次只處理 prompt 指定的 TASK_IDagent_id,不得掃描或執行其他 task directory。
  • 完成後正常退出。不建立背景守護程序或長期監聽器。
  • TASK_ID 必須符合安全 slug:只允許英數、._-,不得為 ...,不得含 /

處理流程

  1. 驗證 prompt 指定的 TASK_IDagent_id,讀取 .lat/workspace/<TASK_ID>/tasks.yamlresults.yaml
  2. 任一 ledger 遺失、空字串、格式錯誤,或找不到精確 agent_id → 依 ../lat-dispatch/references/yaml-schema.md 回報非零錯誤,不建立或清空檔案。
  3. 若已存在相同 task_id + agent_idcompleted result,但 task 尚非 completed,只將 task 原子更新為 completed,不重做實作。
  4. task 必須是 pending 或可恢復的 runningpartialfailedcompleted 不直接重做,交由 Dispatch 建立下一個 agent instance。
  5. 將 task 原子更新為 running,再依以下檢查清單執行:
- [ ] 讀取任務的 goal、context、constraints
- [ ] 若有 plan_file → 讀取計劃檔案,確認階段順序
- [ ] 判斷是否匹配可用領域技能,匹配時載入
- [ ] 依計劃階段順序(或 goal)執行實作
- [ ] 以相同 task_id + agent_id 原子 upsert results.yaml
- [ ] 將 tasks.yaml 中同一筆 task 原子更新為相同最終 status

補充規則:

  • 開始任何 ledger mutation 前,必須完整讀取 ../lat-dispatch/references/yaml-schema.md,並依其必填欄位、欄位名稱、欄位順序與原子寫入規則處理。
  • context.plan_file 時,必須先讀取計劃,依定義的階段順序執行。每個階段完成後專案應可執行。
  • 無計劃檔案的簡單任務:依 goal 直接執行。
  • 技能不得擴大任務範圍;與 constraints 衝突時以 constraints 為準。
  • 不刪除任何 task 或 result 歷史。
  • 每次寫回先在同目錄建立暫存檔,完整解析並驗證後以 mv 原子替換目標檔。
  • result 先寫、task status 後寫;若兩步間中斷,下次依精確 completed result reconciliation,不重複執行。
  • partialfailed 寫回後立即退出並保留該 task;Dispatch 決定是否新增下一個 agent instance。

結果狀態

狀態 意義
completed 任務目標完全實現
partial 部分實現;summary 須說明已完成與未完成範圍
failed 未完成;errors 須包含至少一個 {code, message} 物件

後續任務

  • 僅在大型任務需拆分且剩餘工作可追蹤時才新增。
  • 沿用相同 task_id(Spec 檔名),由 Dispatch 在同一 tasks.yaml 新增遞增 instance 的 agent_id(如 code_executor_2_<task_id>),created_by 填入 Dispatch 識別名稱。
  • 僅限實作任務,不新增審查類任務。

完成輸出

  • 精確 task 不存在或不可執行 → 輸出錯誤並非零退出。
  • 有任務 → 輸出最終 status、修改檔案清單與 ledger 路徑。
  • 處理完成後不保持 zmx 工作階段。

注意事項

Read the full file on GitHub · 69 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago First seen · 69 lines · 66 tokens per session scan A 84903f8862aa

Subscribe to this mod's changes

lat-code is a skill published in the GitHub repository ouob-tw/LoopAgentTeams (7 stars, last pushed 20d ago), licensed MIT. It adds 66 tokens to every session and 1,300 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

Other skills, from other repositories

spec-flow-setup

Set up or repair this repo's spec-flow contract — run init, fill the fields it could not read, make the test command emit a report the engine can read, and prove the result with a green check. Use when a repo has no .spec-flow/config.json, when init left MISSING or REVIEW lines, when a run refuses to start because the…

IgnacioMarin402/spec-flow-plugin · 96 tokens

engine-comments

Decide where a piece of reasoning belongs when writing or editing this engine — an invariant beside the code, a transition in the commit message, or a decision in decisions/. Use when adding a comment or a file header to hooks/, scripts/, commands/ or agents/, when a header has grown past what a reader needs, or when…

IgnacioMarin402/spec-flow-plugin · 74 tokens

foundry-config-setup

Resolve missing setup caused by a hardcoded Foundry project endpoint or model in a sample. Use when a sample fails because it uses a placeholder/hardcoded projectendpoint (for example "https://your-project.services.ai.azure.com") or a hardcoded model instead of reading them from the environment.

microsoft/agent-framework · 65 tokens

gsd-audit-milestone

Audit milestone completion against original intent before archiving.

open-gsd/gsd-core · 17 tokens

spec-kitty-charter-doctrine

Run charter interview, generation, context, and sync workflows for project governance in Spec Kitty 3.x. Access doctrine artifacts programmatically via DoctrineService. Resolve agent profiles. Load action-scoped governance context iteratively, not all at once. Triggers: "interview for charter", "generate charter"…

Priivacy-ai/spec-kitty · 135 tokens

oma-scholar

Scholarly research companion using Knows sidecar spec (.knows.yaml). Generates, validates, reviews, queries, and compares structured research-paper sidecars, and fetches them from knows.academy. Use for academic literature search, survey synthesis, paper authoring assistance, and peer review with token-efficient…

first-fluke/oh-my-agent · 73 tokens