Skip to content

feat: add GitHub API query tools and per-tool PII exemptions#38

Merged
initializ-mk merged 1 commit intomainfrom
skills/gh
Mar 26, 2026
Merged

feat: add GitHub API query tools and per-tool PII exemptions#38
initializ-mk merged 1 commit intomainfrom
skills/gh

Conversation

@initializ-mk
Copy link
Copy Markdown
Contributor

Summary

  • Add 6 new read-only GitHub API tools to the github skill: github_list_prs, github_get_user, github_list_stargazers, github_list_forks, github_pr_author_profiles (compound 2-step), and github_stargazer_profiles (compound 2-step). All list tools support pagination via page/per_page parameters.
  • Add allow_tools config to the guardrail engine's no_pii guardrail, enabling specific tools to bypass PII checks when returning public profile data (emails, bios). Write tools (file_create, code_agent_write, code_agent_edit) are also exempted since they only echo content already in the LLM context.
  • Update error messages from generic "tool output blocked by content policy" to guardrail-specific messages (e.g., "tool output blocked by no_pii guardrail (PII detected in output)").

Test plan

  • golangci-lint passes for forge-core and forge-cli
  • TestToolPhaseClassification — all 6 new tools classified as phaseExplore
  • TestCheckToolOutput_AllowToolsBypassesPII — allowed tools pass, others blocked
  • TestCheckToolOutput_AllowToolsOnlyAffectsConfiguredGuardrailno_pii allowlist does not bypass no_secrets
  • TestCheckToolOutput_ErrorMessageMentionsGuardrailType — verifies guardrail name in errors
  • All shell scripts pass bash -n syntax check
  • Manual: run github_pr_author_profiles against a real repo and verify PII passes through without guardrail block

Add 6 new read-only GitHub API tools to the github skill: github_list_prs,
github_get_user, github_list_stargazers, github_list_forks,
github_pr_author_profiles, and github_stargazer_profiles. All list tools
support pagination via page/per_page parameters.

Add allow_tools config to the guardrail engine so specific tools can bypass
PII checks when returning public profile data. Update error messages to
identify which guardrail triggered (no_pii vs no_secrets). Pre-configure
the default policy scaffold with exemptions for GitHub profile tools and
write tools that echo allowed content.
@initializ-mk initializ-mk merged commit e5d39aa into main Mar 26, 2026
9 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