Skip to content

API Reference parrot_tools.business_automation.memory

github-actions[bot] edited this page Dec 2, 2026 · 4 revisions

parrot_tools.business_automation.memory

View source

gestoria wiki plane + Obsidian mirror (FEAT-453, Module 10, Goal G8).

Instantiates FEAT-452's domain-plane recipe (already proven in-repo by TASK-2379's notes plane, see agents/fireflies_wiki.py::_build_notes_wiki_toolkit) for a dedicated gestoria wiki: its own LLMWikiToolkit instance, own storage root, own PageIndex authoring plane, and own GraphIndex tenant (tenant_id="gestoria"). This is not a parameter passed to an existing wiki — LLMWikiToolkit._config_for() resolves a registered namespace name to the SAME config (a namespace query concern, per the FEAT-450 merge), it does not give a namespace its own storage plane. A second toolkit instance is mandatory for a genuinely separate plane.

Namespace registration (wikitoolkit ns add) is an explicit operator runbook step (see wiki/operations/business-automation-runbook.md), never agent code (FEAT-452 TASK-2382 non-scope) — an unregistered plane silently accumulates knowledge nobody can retrieve via wikitoolkit query.

Attribute GESTORIA_FOLDER

Type: str

Attribute GESTORIA_WIKI_NAME

Type: str

Attribute GESTORIA_WIKI_STORAGE_DIR

Type: Path

Alias LLMWikiToolkit

Re-exported from parrot_tools.wiki.LLMWikiToolkit.

Function build_gestoria_wiki

Construct the dedicated gestoria LLMWikiToolkit.

Bootstraps the layout with an idempotent create_wiki() call so repeat calls (e.g. process restarts) never error. Best-effort throughout: any failure logs a warning naming "gestoria" and returns None so the calling agent still boots.

build_gestoria_wiki(*, storage_dir: Optional[Path] = None, wiki_name: str = GESTORIA_WIKI_NAME, agent_id: str = 'gestoria') -> Optional['LLMWikiToolkit']

Parameter Type Default Description
storage_dir Optional[Path] None Storage root override (default: GESTORIA_WIKI_STORAGE_DIR, expanded from $GESTORIA_WIKI_STORAGE_DIR or ~/.parrot/wikis/gestoria).
wiki_name str GESTORIA_WIKI_NAME Wiki name override (default: GESTORIA_WIKI_NAME).
agent_id str 'gestoria' Identity stamped onto pages this plane authors.

Returns: Optional['LLMWikiToolkit'] — A wired LLMWikiToolkit for the gestoria plane, or None when construction fails.

Attribute logger

Function record_operation_page

Record one completed business operation as a page, mirrored to Obsidian.

Records: what ran (operation), a stable digest of its parameters (never the raw values), the confirmation-gate decision, and the outcome. Both the wiki write and the Obsidian mirror are best-effort — a failure in either is logged and does not raise, since this is an audit/knowledge side effect, not the operation's own result.

record_operation_page(*, wiki: Optional['LLMWikiToolkit'], obsidian: Optional['ObsidianToolkit'], operation: str, params: Dict[str, Any], gate_decision: str, outcome: str, run_id: str, wiki_name: str = GESTORIA_WIKI_NAME, folder: str = GESTORIA_FOLDER) -> Dict[str, Any]

Parameter Type Default Description
wiki Optional['LLMWikiToolkit'] The gestoria :class:LLMWikiToolkit (from :func:build_gestoria_wiki); None skips the wiki write.
obsidian Optional['ObsidianToolkit'] An :class:ObsidianToolkit mirroring into the vault; None skips the Obsidian mirror.
operation str The :class:~parrot_tools.business_automation.models.BusinessOperation name that ran.
params Dict[str, Any] The parameters it ran with (digested, never stored raw).
gate_decision str The :class:~parrot.auth.confirmation.ConfirmationDecision status (e.g. "confirmed", "not_required", "cancelled").
outcome str The run's final status (e.g. "done", "failed").
run_id str The BusinessAutomationToolkit run id.
wiki_name str GESTORIA_WIKI_NAME Wiki name to create the page in.
folder str GESTORIA_FOLDER Obsidian vault subfolder for the mirror.

Returns: Dict[str, Any] — {"wiki": <create_page result or None>, "obsidian": <create_note result or None>}.

Architecture

Clients

Bots & Agents

Memory

Knowledge

Tools & Toolkits

Flows

Experts

Skills

Stores & Loaders

MCP & A2A

Server & APIs

Integrations

Outputs & A2UI

Prompts

Security

Operations

Migration

SDD Tooling

LLM Wiki

Deployment

Decisions

API Reference

Clone this wiki locally