Skip to content

feat: wiki toggle via team config + local override (Approach C)#24

Closed
jeff-r2026 wants to merge 2 commits into
mainfrom
feat/wiki-toggle-team-config
Closed

feat: wiki toggle via team config + local override (Approach C)#24
jeff-r2026 wants to merge 2 commits into
mainfrom
feat/wiki-toggle-team-config

Conversation

@jeff-r2026
Copy link
Copy Markdown
Collaborator

Summary

Approach C: Team Config + Local Override — The most comprehensive approach with multi-level control.

Priority chain: env var > local config > team config > default (enabled)

  • Team admin can disable wiki for the entire team in teamai.yaml
  • Individual users can override in ~/.teamai/config.yaml
  • Env var TEAMAI_WIKI_DISABLED=1 is the highest-priority escape hatch

How to disable:

Team-level (affects all members):

# teamai.yaml
sharing:
  wiki:
    enabled: false
    disabledHint: "use external team-wiki plugin"

User-level (override team setting):

# ~/.teamai/config.yaml
wikiEnabled: false   # or true to re-enable despite team disabling

Env var (highest priority):

export TEAMAI_WIKI_DISABLED=1

When disabled:

  • Wiki resources skipped during teamai pull / teamai push
  • teamai-wiki builtin skill not deployed
  • teamai status shows wiki status with source info (team/local/env)

Trade-offs:

Pros Cons
Team-level enforcement More complex implementation
User autonomy (override) 3 levels to understand
Env var escape hatch More code to maintain
Clear status with source Slightly more cognitive load

Backward compatibility:

  • Old teamai.yaml without wiki section → enabled (default)
  • Old config.yaml without wikiEnabled → follow team config
  • Env var not set → follow config chain

Test plan

  • resolveWikiEnabled() priority: env > local > team > default
  • Team config with/without wiki section
  • Local config with/without wikiEnabled
  • All env var combinations tested
  • Pull/push correctly filter wiki resources
  • All tests pass (27 new tests + existing suite)
  • TypeScript compiles cleanly

Closes #21

💡 This is 1 of 3 alternative implementations. See also:

  • Approach A: Environment variable (feat/wiki-toggle-env)
  • Approach B: Local config (feat/wiki-toggle-local-config)

jeff-r2026 and others added 2 commits May 26, 2026 20:51
 #21)

Add ability to disable the built-in wiki feature at the team level
(teamai.yaml sharing.wiki.enabled) with optional local user override
(config.yaml wikiEnabled). This allows teams using third-party wiki
plugins to disable the built-in wiki without affecting other teams.

Priority: env var (TEAMAI_WIKI_DISABLED) > local config > team config > default (enabled)

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Verify that TEAMAI_WIKI_DISABLED=1 takes highest priority over both
local config (wikiEnabled: true) and team config (sharing.wiki.enabled: true).

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@jeff-r2026
Copy link
Copy Markdown
Collaborator Author

Closing in favor of Approach A (#22 - env var)

@jeff-r2026 jeff-r2026 closed this May 27, 2026
@jeff-r2026 jeff-r2026 deleted the feat/wiki-toggle-team-config branch May 27, 2026 02:42
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.

[feat] Wiki 功能开关:避免与第三方 team-wiki 插件命名冲突导致 AI 误识别

1 participant