Skip to content

refactor(core): move tool registry contracts into agent-tools#708

Merged
limityan merged 2 commits into
GCWing:mainfrom
limityan:yanzhn/refactor-agent-tools
May 13, 2026
Merged

refactor(core): move tool registry contracts into agent-tools#708
limityan merged 2 commits into
GCWing:mainfrom
limityan:yanzhn/refactor-agent-tools

Conversation

@limityan
Copy link
Copy Markdown
Collaborator

Summary

  • Move lightweight tool contracts plus the generic tool registry / dynamic-provider container into bitfun-agent-tools.
  • Keep bitfun-core registry as product runtime assembly: builtin tool list, dyn Tool adapter, snapshot decoration, and legacy compatibility paths.
  • Add boundary checks and concise docs/AGENTS guidance so ToolUseContext and concrete tool implementations stay core-owned until a reviewed port/provider design and equivalence tests exist.

Guardrails

  • No concrete tool implementation or ToolUseContext migration in this PR.
  • No product feature matrix, default feature, build script, or release script changes.
  • Dynamic tool metadata, descriptor shape/order, readonly/builtin tool lists, and snapshot wrapping remain covered by tests.

Validation

  • node scripts/check-core-boundaries.mjs
  • rustfmt --edition 2021 --check src\crates\agent-tools\src\framework.rs src\crates\agent-tools\src\lib.rs src\crates\agent-tools\tests\tool_contracts.rs src\crates\core\src\agentic\tools\framework.rs src\crates\core\src\agentic\tools\registry.rs src\crates\core\src\agentic\tools\restrictions.rs src\crates\core\src\agentic\tools\pipeline\tool_pipeline.rs src\crates\runtime-ports\src\lib.rs
  • git diff --check gcwing/main..HEAD
  • cargo test -p bitfun-agent-tools
  • cargo test -p bitfun-runtime-ports
  • cargo test -p bitfun-core registry_ --lib
  • cargo test -p bitfun-core dynamic_tool_provider_ --lib
  • cargo check --workspace (passes with existing bitfun-cli unused Read warning)
  • cargo test --workspace (passes with existing bitfun-cli unused Read warning)

@limityan limityan merged commit b853282 into GCWing:main May 13, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant