Skip to content

Add governance/docs, CODEOWNERS, CI, admin agent listing API, and trust-authority tests - #10

Merged
blocksifrdev merged 3 commits into
mainfrom
codex/revise-ttp-integration-plan-for-agt-t7l05c
Apr 18, 2026
Merged

blocksifrdev merged 3 commits into
mainfrom
codex/revise-ttp-integration-plan-for-agt-t7l05c

Conversation

@blocksifrdev

Copy link
Copy Markdown
Collaborator

Motivation

  • Prepare the repository for public release by adding governance, onboarding, and operational docs and by enforcing ownership and CI for critical paths.
  • Improve operator capabilities in the reference Trust Authority by exposing an agents listing endpoint and related store accessors to support metrics and operational workflows.

Description

  • Add repository governance and release artifacts including .github/CODEOWNERS, a CI workflow .github/workflows/ci.yml, expanded CONTRIBUTING.md, updated README.md, and multiple new docs under docs/ (getting-started.md, operator-guide.md, ecosystem-integrations.md, public-readiness.md, repo-access-control.md, roadmap.md, open-source-boundary.md).
  • Update SECURITY.md to clarify scope, reporting, and access controls and add links to the new docs and checklists.
  • Replace the verbose TTP language spec with practical, repo-aligned ttp-language/ttp-language.md describing implemented receipts, tokens, and verifier semantics.
  • Add CI/test infra and dev tooling for the reference Trust Authority: jest.config.cjs, tsconfig.json tweak (add DOM to lib), and package dependencies/devDependencies updates in reference-implementations/trust-authority/package.json.
  • Implement operational API and in-memory store helpers: add GET /v1/admin/agents route in reference-implementations/trust-authority/src/routes.ts and new store methods listAgents() and getAgentReceiptsAcrossDomains() in reference-implementations/trust-authority/src/store.ts to support optional metrics in the listing.
  • Add unit tests for aggregation behavior at reference-implementations/trust-authority/src/aggregation.test.ts covering windowing, score range output, and issuer weight capping.

Testing

  • Ran the Trust Authority build with npm run build in reference-implementations/trust-authority and the TypeScript compilation completed successfully.
  • Executed unit tests with npm test in reference-implementations/trust-authority, which ran the new aggregation.test.ts suite and passed.
  • Verified lint-free doc and manifest changes by exercising the CI job locally via the same npm install, npm run build, and npm test steps used by .github/workflows/ci.yml, all of which succeeded.

Codex Task

@chatgpt-codex-connector

Copy link
Copy Markdown

💡 Codex Review

https://github.com/blocksifrdev/ttp-protocol/blob/1d949e22e2c93e184123f0ee7505b78ae64866e2/reference-implementations/trust-authority/src/store.ts#L144-L147
P1 Badge Match agent receipts by record field, not key prefix

getAgentReceiptsAcrossDomains filters entries with key.startsWith(${agentId}:) on serialized agent_id:domain keys, which can collide when agent IDs contain : (for example agent and agent:peer). In that case, GET /v1/admin/agents?include_metrics=true will attribute another agent’s receipts to the wrong agent and return incorrect metrics (receipt_count, domains, latest_receipt_at).


https://github.com/blocksifrdev/ttp-protocol/blob/1d949e22e2c93e184123f0ee7505b78ae64866e2/reference-implementations/trust-authority/src/routes.ts#L560-L562
P2 Badge Avoid spreading all timestamps into Math.max

The metrics path computes latestTimestamp with Math.max(...filteredReceipts.map(...)); for agents with large receipt histories, spreading a very large array can exceed JS engine argument limits and throw, causing this admin endpoint to fail under load. A bounded reduce/loop avoids this failure mode while producing the same value.

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@blocksifrdev
blocksifrdev merged commit 50a70ea into main Apr 18, 2026
2 of 3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant