Skip to content

feat: agent-friendly zero-interactive setup - #33

Closed
the-herbalist wants to merge 3 commits into
MemPalace:mainfrom
the-herbalist:agent-setup
Closed

feat: agent-friendly zero-interactive setup#33
the-herbalist wants to merge 3 commits into
MemPalace:mainfrom
the-herbalist:agent-setup

Conversation

@the-herbalist

Copy link
Copy Markdown

What This Does

Makes MemPalace fully setup-able by AI agents with zero interactive prompts. Three non-breaking additions:

  1. MEMPALACE_NONINTERACTIVE env var — Respects this env var (in addition to existing --yes flag) to skip all input() prompts in confirm_entities(). Works as a global kill switch for interactive mode.

  2. mempalace mine --auto — Auto-detects whether the target directory contains project files or conversation exports by scanning for known patterns (Claude/ChatGPT transcripts, Slack exports, OpenAI JSON format, etc.). Picks the right mining mode automatically.

  3. mempalace agent-setup <dir> command — One-shot non-interactive setup: init + auto-detect content + mine + status verification. Forces non-interactive mode internally. Returns exit code 0 on success.

  4. AGENT.md — Agent discovery document at repo root. Written for LLM parsing — any AI agent finding this repo can execute the setup flow autonomously.

Usage

bash
Existing behavior unchanged
mempalace init ~/project --yes

New — agent-friendly
MEMPALACE_NONINTERACTIVE=1 mempalace init ~/project
mempalace mine ~/project --auto
mempalace agent-setup ~/project

Backward Compatibility

  • All existing commands work identically
  • --yes flag on init is unchanged
  • --mode auto is opt-in (default is still projects)
  • agent-setup is a new subcommand, no collision
  • Zero breaking changes

Files Changed

  • mempalace/cli.py (+182 lines: _detect_mine_mode, cmd_agent_setup, --mode auto support)
  • mempalace/entity_detector.py (+3 lines: env var check in confirm_entities)
  • AGENT.md (new file, agent setup documentation)

IgorTavcar added a commit to IgorTavcar/mempalace that referenced this pull request Apr 7, 2026
Cherry-picked from upstream PR MemPalace#33 (the-herbalist).
- Add MEMPALACE_NONINTERACTIVE env var to skip all prompts
- Add `mempalace mine --auto` for auto-detection of content type
- Add `mempalace agent-setup <dir>` one-shot command
- Add AGENT.md for LLM discoverability

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@bensig

bensig commented Apr 7, 2026

Copy link
Copy Markdown
Contributor

Fixed in #123mempalace init --yes is now fully non-interactive. Closing as duplicate.

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.

2 participants