Files
2025-07-15 19:48:09 +00:00

120 lines
62 KiB
HTML
Raw Permalink Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<!doctype html>
<html lang="en" dir="ltr" class="docs-wrapper plugin-docs plugin-id-default docs-version-current docs-doc-page docs-doc-id-tutorials/advanced-cognee-usage" data-has-hydrated="false">
<head>
<meta charset="UTF-8">
<meta name="generator" content="Docusaurus v3.7.0">
<title data-rh="true">Advanced Cognee Usage with Goose | codename goose</title><meta data-rh="true" name="viewport" content="width=device-width,initial-scale=1"><meta data-rh="true" name="twitter:card" content="summary_large_image"><meta data-rh="true" property="og:image" content="https://block.github.io/goose/img/home-banner.png"><meta data-rh="true" name="twitter:image" content="https://block.github.io/goose/img/home-banner.png"><meta data-rh="true" property="og:url" content="https://block.github.io/goose/docs/tutorials/advanced-cognee-usage"><meta data-rh="true" property="og:locale" content="en"><meta data-rh="true" name="docusaurus_locale" content="en"><meta data-rh="true" name="docsearch:language" content="en"><meta data-rh="true" name="docusaurus_version" content="current"><meta data-rh="true" name="docusaurus_tag" content="docs-default-current"><meta data-rh="true" name="docsearch:version" content="current"><meta data-rh="true" name="docsearch:docusaurus_tag" content="docs-default-current"><meta data-rh="true" property="og:title" content="Advanced Cognee Usage with Goose | codename goose"><meta data-rh="true" name="description" content="Advanced patterns for using Cognee knowledge graph with Goose for enhanced memory and automation"><meta data-rh="true" property="og:description" content="Advanced patterns for using Cognee knowledge graph with Goose for enhanced memory and automation"><link data-rh="true" rel="icon" href="/goose/img/favicon.ico"><link data-rh="true" rel="canonical" href="https://block.github.io/goose/docs/tutorials/advanced-cognee-usage"><link data-rh="true" rel="alternate" href="https://block.github.io/goose/docs/tutorials/advanced-cognee-usage" hreflang="en"><link data-rh="true" rel="alternate" href="https://block.github.io/goose/docs/tutorials/advanced-cognee-usage" hreflang="x-default"><link rel="alternate" type="application/rss+xml" href="/goose/blog/rss.xml" title="codename goose RSS Feed">
<link rel="alternate" type="application/atom+xml" href="/goose/blog/atom.xml" title="codename goose Atom Feed">
<link rel="preconnect" href="https://www.google-analytics.com">
<link rel="preconnect" href="https://www.googletagmanager.com">
<script async src="https://www.googletagmanager.com/gtag/js?id=G-ZS5D6SB4ZJ"></script>
<script>function gtag(){dataLayer.push(arguments)}window.dataLayer=window.dataLayer||[],gtag("js",new Date),gtag("config","G-ZS5D6SB4ZJ",{anonymize_ip:!0})</script><link rel="stylesheet" href="/goose/assets/css/styles.4f50fa0c.css">
<script src="/goose/assets/js/runtime~main.51418f2b.js" defer="defer"></script>
<script src="/goose/assets/js/main.404fc221.js" defer="defer"></script>
</head>
<body class="navigation-with-keyboard">
<script>!function(){function t(t){document.documentElement.setAttribute("data-theme",t)}var e=function(){try{return new URLSearchParams(window.location.search).get("docusaurus-theme")}catch(t){}}()||function(){try{return window.localStorage.getItem("theme")}catch(t){}}();t(null!==e?e:"light")}(),function(){try{const n=new URLSearchParams(window.location.search).entries();for(var[t,e]of n)if(t.startsWith("docusaurus-data-")){var a=t.replace("docusaurus-data-","data-");document.documentElement.setAttribute(a,e)}}catch(t){}}()</script><div id="__docusaurus"><link rel="preload" as="image" href="/goose/img/logo_light.png"><link rel="preload" as="image" href="/goose/img/logo_dark.png"><div role="region" aria-label="Skip to main content"><a class="skipToContent_fXgn" href="#__docusaurus_skipToContent_fallback">Skip to main content</a></div><nav aria-label="Main" class="navbar navbar--fixed-top"><div class="navbar__inner"><div class="navbar__items"><button aria-label="Toggle navigation bar" aria-expanded="false" class="navbar__toggle clean-btn" type="button"><svg width="30" height="30" viewBox="0 0 30 30" aria-hidden="true"><path stroke="currentColor" stroke-linecap="round" stroke-miterlimit="10" stroke-width="2" d="M4 7h22M4 15h22M4 23h22"></path></svg></button><a class="navbar__brand" href="/goose/"><div class="navbar__logo"><img src="/goose/img/logo_light.png" alt="Block Logo" class="themedComponent_mlkZ themedComponent--light_NVdE"><img src="/goose/img/logo_dark.png" alt="Block Logo" class="themedComponent_mlkZ themedComponent--dark_xIcU"></div><b class="navbar__title text--truncate"></b></a><a class="navbar__item navbar__link" href="/goose/docs/quickstart">Quickstart</a><a class="navbar__item navbar__link" href="/goose/docs/category/guides">Docs</a><a class="navbar__item navbar__link" href="/goose/docs/category/tutorials">Tutorials</a><a class="navbar__item navbar__link" href="/goose/docs/category/mcp-servers">MCPs</a><a class="navbar__item navbar__link" href="/goose/blog">Blog</a><div class="navbar__item dropdown dropdown--hoverable"><a href="#" aria-haspopup="true" aria-expanded="false" role="button" class="navbar__link">Resources</a><ul class="dropdown__menu"><li><a class="dropdown__link" href="/goose/extensions">Extensions</a></li><li><a class="dropdown__link" href="/goose/recipe-generator">Recipe Generator</a></li><li><a class="dropdown__link" href="/goose/prompt-library">Prompt Library</a></li><li><a class="dropdown__link" href="/goose/recipes">Recipe Cookbook</a></li><li><a class="dropdown__link" href="/goose/deeplink-generator">Deeplink Generator</a></li></ul></div></div><div class="navbar__items navbar__items--right"><a href="https://discord.gg/block-opensource" target="_blank" rel="noopener noreferrer" class="navbar__item navbar__link">Discord<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_nPIU"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a><a href="https://github.com/block/goose" target="_blank" rel="noopener noreferrer" class="navbar__item navbar__link">GitHub<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_nPIU"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a><div class="toggle_vylO colorModeToggle_DEke"><button class="clean-btn toggleButton_gllP toggleButtonDisabled_aARS" type="button" disabled="" title="Switch between dark and light mode (currently light mode)" aria-label="Switch between dark and light mode (currently light mode)" aria-live="polite" aria-pressed="false"><svg viewBox="0 0 24 24" width="24" height="24" class="lightToggleIcon_pyhR"><path fill="currentColor" d="M12,9c1.65,0,3,1.35,3,3s-1.35,3-3,3s-3-1.35-3-3S10.35,9,12,9 M12,7c-2.76,0-5,2.24-5,5s2.24,5,5,5s5-2.24,5-5 S14.76,7,12,7L12,7z M2,13l2,0c0.55,0,1-0.45,1-1s-0.45-1-1-1l-2,0c-0.55,0-1,0.45-1,1S1.45,13,2,13z M20,13l2,0c0.55,0,1-0.45,1-1 s-0.45-1-1-1l-2,0c-0.55,0-1,0.45-1,1S19.45,13,20,13z M11,2v2c0,0.55,0.45,1,1,1s1-0.45,1-1V2c0-0.55-0.45-1-1-1S11,1.45,11,2z M11,20v2c0,0.55,0.45,1,1,1s1-0.45,1-1v-2c0-0.55-0.45-1-1-1C11.45,19,11,19.45,11,20z M5.99,4.58c-0.39-0.39-1.03-0.39-1.41,0 c-0.39,0.39-0.39,1.03,0,1.41l1.06,1.06c0.39,0.39,1.03,0.39,1.41,0s0.39-1.03,0-1.41L5.99,4.58z M18.36,16.95 c-0.39-0.39-1.03-0.39-1.41,0c-0.39,0.39-0.39,1.03,0,1.41l1.06,1.06c0.39,0.39,1.03,0.39,1.41,0c0.39-0.39,0.39-1.03,0-1.41 L18.36,16.95z M19.42,5.99c0.39-0.39,0.39-1.03,0-1.41c-0.39-0.39-1.03-0.39-1.41,0l-1.06,1.06c-0.39,0.39-0.39,1.03,0,1.41 s1.03,0.39,1.41,0L19.42,5.99z M7.05,18.36c0.39-0.39,0.39-1.03,0-1.41c-0.39-0.39-1.03-0.39-1.41,0l-1.06,1.06 c-0.39,0.39-0.39,1.03,0,1.41s1.03,0.39,1.41,0L7.05,18.36z"></path></svg><svg viewBox="0 0 24 24" width="24" height="24" class="darkToggleIcon_wfgR"><path fill="currentColor" d="M9.37,5.51C9.19,6.15,9.1,6.82,9.1,7.5c0,4.08,3.32,7.4,7.4,7.4c0.68,0,1.35-0.09,1.99-0.27C17.45,17.19,14.93,19,12,19 c-3.86,0-7-3.14-7-7C5,9.07,6.81,6.55,9.37,5.51z M12,3c-4.97,0-9,4.03-9,9s4.03,9,9,9s9-4.03,9-9c0-0.46-0.04-0.92-0.1-1.36 c-0.98,1.37-2.58,2.26-4.4,2.26c-2.98,0-5.4-2.42-5.4-5.4c0-1.81,0.89-3.42,2.26-4.4C12.92,3.04,12.46,3,12,3L12,3z"></path></svg></button></div><div class="navbarSearchContainer_Bca1"><div id="inkeep"></div></div></div></div><div role="presentation" class="navbar-sidebar__backdrop"></div></nav><div id="__docusaurus_skipToContent_fallback" class="main-wrapper mainWrapper_z2l0"><div class="docsWrapper_hBAB"><button aria-label="Scroll back to top" class="clean-btn theme-back-to-top-button backToTopButton_sjWU" type="button"></button><div class="docRoot_UBD9"><aside class="theme-doc-sidebar-container docSidebarContainer_YfHR"><div class="sidebarViewport_aRkj"><div class="sidebar_njMd"><nav aria-label="Docs sidebar" class="menu thin-scrollbar menu_SIkG"><ul class="theme-doc-sidebar-menu menu__list"><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-1 menu__list-item"><a class="menu__link" href="/goose/docs/quickstart">Quickstart</a></li><li class="theme-doc-sidebar-item-category theme-doc-sidebar-item-category-level-1 menu__list-item menu__list-item--collapsed"><div class="menu__list-item-collapsible"><a class="menu__link menu__link--sublist" href="/goose/docs/category/getting-started">Getting Started</a><button aria-label="Expand sidebar category &#x27;Getting Started&#x27;" aria-expanded="false" type="button" class="clean-btn menu__caret"></button></div></li><li class="theme-doc-sidebar-item-category theme-doc-sidebar-item-category-level-1 menu__list-item menu__list-item--collapsed"><div class="menu__list-item-collapsible"><a class="menu__link menu__link--sublist" href="/goose/docs/category/guides">Guides</a><button aria-label="Expand sidebar category &#x27;Guides&#x27;" aria-expanded="false" type="button" class="clean-btn menu__caret"></button></div></li><li class="theme-doc-sidebar-item-category theme-doc-sidebar-item-category-level-1 menu__list-item"><div class="menu__list-item-collapsible"><a class="menu__link menu__link--sublist menu__link--active" href="/goose/docs/category/tutorials">Tutorials</a><button aria-label="Collapse sidebar category &#x27;Tutorials&#x27;" aria-expanded="true" type="button" class="clean-btn menu__caret"></button></div><ul style="display:block;overflow:visible;height:auto" class="menu__list"><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-2 menu__list-item"><a class="menu__link menu__link--active" aria-current="page" tabindex="0" href="/goose/docs/tutorials/advanced-cognee-usage">Advanced Cognee Usage with Goose</a></li><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-2 menu__list-item"><a class="menu__link" tabindex="0" href="/goose/docs/tutorials/benchmarking">Benchmark with Goose</a></li><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-2 menu__list-item"><a class="menu__link" tabindex="0" href="/goose/docs/tutorials/cicd">CI/CD Environments</a></li><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-2 menu__list-item"><a class="menu__link" tabindex="0" href="/goose/docs/tutorials/custom-extensions">Building Custom Extensions</a></li><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-2 menu__list-item"><a class="menu__link" tabindex="0" href="/goose/docs/tutorials/goose-in-docker">Goose in Docker</a></li><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-2 menu__list-item"><a class="menu__link" tabindex="0" href="/goose/docs/tutorials/isolated-development-environments">Isolated Development Environments</a></li><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-2 menu__list-item"><a class="menu__link" tabindex="0" href="/goose/docs/tutorials/langfuse">Observability with Langfuse</a></li><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-2 menu__list-item"><a class="menu__link" tabindex="0" href="/goose/docs/tutorials/lead-worker">Lead/Worker Multi-Model Setup</a></li><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-2 menu__list-item"><a class="menu__link" tabindex="0" href="/goose/docs/tutorials/recipes-tutorial">Goose Recipes</a></li></ul></li><li class="theme-doc-sidebar-item-category theme-doc-sidebar-item-category-level-1 menu__list-item menu__list-item--collapsed"><div class="menu__list-item-collapsible"><a class="menu__link menu__link--sublist" href="/goose/docs/category/mcp-servers">MCP Servers</a><button aria-label="Expand sidebar category &#x27;MCP Servers&#x27;" aria-expanded="false" type="button" class="clean-btn menu__caret"></button></div></li><li class="theme-doc-sidebar-item-category theme-doc-sidebar-item-category-level-1 menu__list-item menu__list-item--collapsed"><div class="menu__list-item-collapsible"><a class="menu__link menu__link--sublist" href="/goose/docs/category/architecture-overview">Architecture Overview</a><button aria-label="Expand sidebar category &#x27;Architecture Overview&#x27;" aria-expanded="false" type="button" class="clean-btn menu__caret"></button></div></li><li class="theme-doc-sidebar-item-category theme-doc-sidebar-item-category-level-1 menu__list-item menu__list-item--collapsed"><div class="menu__list-item-collapsible"><a class="menu__link menu__link--sublist" href="/goose/docs/experimental/">Experimental</a><button aria-label="Expand sidebar category &#x27;Experimental&#x27;" aria-expanded="false" type="button" class="clean-btn menu__caret"></button></div></li><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-1 menu__list-item"><a class="menu__link" href="/goose/docs/troubleshooting">Troubleshooting</a></li></ul></nav></div></div></aside><main class="docMainContainer_TBSr"><div class="container padding-top--md padding-bottom--lg"><div class="row"><div class="col docItemCol_VOVn"><div class="docItemContainer_Djhp"><article><nav class="theme-doc-breadcrumbs breadcrumbsContainer_Z_bl" aria-label="Breadcrumbs"><ul class="breadcrumbs" itemscope="" itemtype="https://schema.org/BreadcrumbList"><li class="breadcrumbs__item"><a aria-label="Home page" class="breadcrumbs__link" href="/goose/"><svg viewBox="0 0 24 24" class="breadcrumbHomeIcon_YNFT"><path d="M10 19v-5h4v5c0 .55.45 1 1 1h3c.55 0 1-.45 1-1v-7h1.7c.46 0 .68-.57.33-.87L12.67 3.6c-.38-.34-.96-.34-1.34 0l-8.36 7.53c-.34.3-.13.87.33.87H5v7c0 .55.45 1 1 1h3c.55 0 1-.45 1-1z" fill="currentColor"></path></svg></a></li><li itemscope="" itemprop="itemListElement" itemtype="https://schema.org/ListItem" class="breadcrumbs__item"><a class="breadcrumbs__link" itemprop="item" href="/goose/docs/category/tutorials"><span itemprop="name">Tutorials</span></a><meta itemprop="position" content="1"></li><li itemscope="" itemprop="itemListElement" itemtype="https://schema.org/ListItem" class="breadcrumbs__item breadcrumbs__item--active"><span class="breadcrumbs__link" itemprop="name">Advanced Cognee Usage with Goose</span><meta itemprop="position" content="2"></li></ul></nav><div class="tocCollapsible_ETCw theme-doc-toc-mobile tocMobile_ITEo"><button type="button" class="clean-btn tocCollapsibleButton_TO0P">On this page</button></div><div class="theme-doc-markdown markdown"><header><h1>Advanced Cognee Usage with Goose</h1></header>
<p>This tutorial covers advanced usage patterns for the Cognee extension with Goose, including automated memory management, knowledge graph optimization, and various integration strategies.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="overview">Overview<a href="#overview" class="hash-link" aria-label="Direct link to Overview" title="Direct link to Overview"></a></h2>
<p>While the basic <a href="/goose/docs/mcp/cognee-mcp">Cognee MCP setup</a> gets you started, this tutorial explores how to make Goose autonomously use the knowledge graph and optimize your workflow.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="key-concepts">Key Concepts<a href="#key-concepts" class="hash-link" aria-label="Direct link to Key Concepts" title="Direct link to Key Concepts"></a></h2>
<h3 class="anchor anchorWithStickyNavbar_LWe7" id="knowledge-graph-memory">Knowledge Graph Memory<a href="#knowledge-graph-memory" class="hash-link" aria-label="Direct link to Knowledge Graph Memory" title="Direct link to Knowledge Graph Memory"></a></h3>
<p>Cognee creates a structured knowledge graph that:</p>
<ul>
<li>Interconnects conversations, documents, images, and audio transcriptions</li>
<li>Supports over 30 data sources</li>
<li>Replaces traditional RAG systems with dynamic relationship mapping</li>
<li>Enables complex multi-hop reasoning</li>
</ul>
<h3 class="anchor anchorWithStickyNavbar_LWe7" id="search-types">Search Types<a href="#search-types" class="hash-link" aria-label="Direct link to Search Types" title="Direct link to Search Types"></a></h3>
<p>Understanding Cognee&#x27;s search types is crucial for effective usage:</p>
<table><thead><tr><th>Search Type</th><th>Use Case</th><th>Description</th></tr></thead><tbody><tr><td><code>SUMMARIES</code></td><td>Summary requests</td><td>High-level overviews</td></tr><tr><td><code>INSIGHTS</code></td><td>Relationship queries</td><td>Connections between entities</td></tr><tr><td><code>CHUNKS</code></td><td>Specific facts</td><td>Raw text segments</td></tr><tr><td><code>COMPLETION</code></td><td>Explanations</td><td>LLM-generated responses</td></tr><tr><td><code>GRAPH_COMPLETION</code></td><td>Complex relations</td><td>Multi-hop reasoning</td></tr><tr><td><code>GRAPH_SUMMARY</code></td><td>Concise answers</td><td>Brief, focused responses</td></tr><tr><td><code>GRAPH_COMPLETION_COT</code></td><td>Multi-hop Q&amp;A</td><td>Chain-of-thought reasoning</td></tr><tr><td><code>GRAPH_CONTEXT_EXT</code></td><td>Context extension</td><td>Expanded context</td></tr><tr><td><code>CODE</code></td><td>Code examples</td><td>Programming-related queries</td></tr></tbody></table>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="automation-strategies">Automation Strategies<a href="#automation-strategies" class="hash-link" aria-label="Direct link to Automation Strategies" title="Direct link to Automation Strategies"></a></h2>
<div class="tabs-container tabList__CuJ"><ul role="tablist" aria-orientation="horizontal" class="tabs"><li role="tab" tabindex="0" aria-selected="true" class="tabs__item tabItem_LNqP tabs__item--active">Method 1 (Slow)</li><li role="tab" tabindex="-1" aria-selected="false" class="tabs__item tabItem_LNqP">Method 2</li></ul><div class="margin-top--md"><div role="tabpanel" class="tabItem_Ymn6"><h3 class="anchor anchorWithStickyNavbar_LWe7" id="instruction-files">Instruction Files<a href="#instruction-files" class="hash-link" aria-label="Direct link to Instruction Files" title="Direct link to Instruction Files"></a></h3><p>Use instruction files for consistent behavior across sessions. This method uses fewer tokens but has slower startup.</p><p>Create <code>~/.config/goose/cognee-instructions.md</code>:</p><div class="language-markdown codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#393A34;--prism-background-color:#f6f8fa"><div class="codeBlockContent_biex"><pre tabindex="0" class="prism-code language-markdown codeBlock_bY9V thin-scrollbar" style="color:#393A34;background-color:#f6f8fa"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#393A34"><span class="token plain">You are an LLM agent with access to a Cognee knowledge graph for memory.</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#393A34"><span class="token plain"></span><span class="token bold punctuation" style="color:#393A34">**</span><span class="token bold content">IMPORTANT RULES:</span><span class="token bold punctuation" style="color:#393A34">**</span><span class="token plain"></span><br></span><span class="token-line" style="color:#393A34"><span class="token plain"></span><span class="token list punctuation" style="color:#393A34">-</span><span class="token plain"> Never call the </span><span class="token code-snippet code keyword" style="color:#00009f">`prune`</span><span class="token plain"> command</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain"></span><span class="token list punctuation" style="color:#393A34">-</span><span class="token plain"> Always search memory before responding to user queries</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain"></span><span class="token list punctuation" style="color:#393A34">-</span><span class="token plain"> Automatically cognify new information you learn about the user</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#393A34"><span class="token plain"></span><span class="token bold punctuation" style="color:#393A34">**</span><span class="token bold content">Memory Workflow:</span><span class="token bold punctuation" style="color:#393A34">**</span><span class="token plain"></span><br></span><span class="token-line" style="color:#393A34"><span class="token plain"></span><span class="token list punctuation" style="color:#393A34">1.</span><span class="token plain"> </span><span class="token bold punctuation" style="color:#393A34">**</span><span class="token bold content">Before each response</span><span class="token bold punctuation" style="color:#393A34">**</span><span class="token plain">: Search the knowledge graph</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain"> </span><span class="token list punctuation" style="color:#393A34">-</span><span class="token plain"> Map user request to appropriate search type:</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain"> </span><span class="token list punctuation" style="color:#393A34">-</span><span class="token plain"> Summary → SUMMARIES</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain"> </span><span class="token list punctuation" style="color:#393A34">-</span><span class="token plain"> Relationships → INSIGHTS </span><br></span><span class="token-line" style="color:#393A34"><span class="token plain"> </span><span class="token list punctuation" style="color:#393A34">-</span><span class="token plain"> Specific facts → CHUNKS</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain"> </span><span class="token list punctuation" style="color:#393A34">-</span><span class="token plain"> Explanations → COMPLETION</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain"> </span><span class="token list punctuation" style="color:#393A34">-</span><span class="token plain"> Complex relations → GRAPH_COMPLETION</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain"> </span><span class="token list punctuation" style="color:#393A34">-</span><span class="token plain"> Code examples → CODE</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain"> </span><br></span><span class="token-line" style="color:#393A34"><span class="token plain"></span><span class="token list punctuation" style="color:#393A34">2.</span><span class="token plain"> </span><span class="token bold punctuation" style="color:#393A34">**</span><span class="token bold content">Search command</span><span class="token bold punctuation" style="color:#393A34">**</span><span class="token plain">:</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain"> ```text</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain"> cognee-mcp__search(\{</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain"> search_query: &quot;user prompt&quot;,</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain"> search_type: &quot;mapped type&quot;</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain"> \})</span><br></span></code></pre><div class="buttonGroup__atx"><button type="button" aria-label="Copy code to clipboard" title="Copy" class="clean-btn"><span class="copyButtonIcons_eSgA" aria-hidden="true"><svg viewBox="0 0 24 24" class="copyButtonIcon_y97N"><path fill="currentColor" d="M19,21H8V7H19M19,5H8A2,2 0 0,0 6,7V21A2,2 0 0,0 8,23H19A2,2 0 0,0 21,21V7A2,2 0 0,0 19,5M16,1H4A2,2 0 0,0 2,3V17H4V3H16V1Z"></path></svg><svg viewBox="0 0 24 24" class="copyButtonSuccessIcon_LjdS"><path fill="currentColor" d="M21,7L9,19L3.5,13.5L4.91,12.09L9,16.17L19.59,5.59L21,7Z"></path></svg></span></button></div></div></div><ol start="3">
<li><strong>Incorporate results</strong> into your response</li>
</ol><p><strong>Memory Updates:</strong></p><ul>
<li>When you learn new facts, preferences, or relationships about the user</li>
<li>Call: <code>cognee-mcp__cognify(\{ data: &quot;information&quot; \})</code></li>
<li>Monitor with: <code>cognee-mcp__cognify_status()</code></li>
</ul><p><strong>Code Analysis:</strong></p><ul>
<li>When asked to analyze code repositories</li>
<li>Use: <code>cognee-mcp__codify(\{ repo_path: &quot;path&quot; \})</code></li>
<li>Only process files returned by <code>rg --files</code></li>
</ul><div class="codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#393A34;--prism-background-color:#f6f8fa"><div class="codeBlockContent_biex"><pre tabindex="0" class="prism-code language-text codeBlock_bY9V thin-scrollbar" style="color:#393A34;background-color:#f6f8fa"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#393A34"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">Start Goose with instructions:</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">```bash</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">goose run -i ~/.config/goose/cognee-instructions.md -s</span><br></span></code></pre><div class="buttonGroup__atx"><button type="button" aria-label="Copy code to clipboard" title="Copy" class="clean-btn"><span class="copyButtonIcons_eSgA" aria-hidden="true"><svg viewBox="0 0 24 24" class="copyButtonIcon_y97N"><path fill="currentColor" d="M19,21H8V7H19M19,5H8A2,2 0 0,0 6,7V21A2,2 0 0,0 8,23H19A2,2 0 0,0 21,21V7A2,2 0 0,0 19,5M16,1H4A2,2 0 0,0 2,3V17H4V3H16V1Z"></path></svg><svg viewBox="0 0 24 24" class="copyButtonSuccessIcon_LjdS"><path fill="currentColor" d="M21,7L9,19L3.5,13.5L4.91,12.09L9,16.17L19.59,5.59L21,7Z"></path></svg></span></button></div></div></div></div><div role="tabpanel" class="tabItem_Ymn6" hidden=""><h3 class="anchor anchorWithStickyNavbar_LWe7" id="goosehints-file">Goosehints File<a href="#goosehints-file" class="hash-link" aria-label="Direct link to Goosehints File" title="Direct link to Goosehints File"></a></h3><p>For faster startup with higher token usage, add to your <code>.goosehints</code> file:</p><div class="language-text codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#393A34;--prism-background-color:#f6f8fa"><div class="codeBlockContent_biex"><pre tabindex="0" class="prism-code language-text codeBlock_bY9V thin-scrollbar" style="color:#393A34;background-color:#f6f8fa"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#393A34"><span class="token plain">COGNEE_MEMORY_SYSTEM:</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">You have access to a Cognee knowledge graph for persistent memory.</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">MEMORY_RETRIEVAL_PROTOCOL:</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">- Before responding, determine request type and map to search type</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">- Search types: SUMMARIES, INSIGHTS, CHUNKS, COMPLETION, GRAPH_COMPLETION, CODE</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">- Always call: cognee-mcp__search with search_query and search_type parameters</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">- Incorporate memory results into responses</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">MEMORY_STORAGE_PROTOCOL:</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">- Auto-cognify new user facts, preferences, relationships</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">- Call: cognee-mcp__cognify with data parameter</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">- Never use prune command</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">CODE_ANALYSIS_PROTOCOL:</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">- For repositories: cognee-mcp__codify with repo_path parameter</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">- Only process files from rg --files output</span><br></span></code></pre><div class="buttonGroup__atx"><button type="button" aria-label="Copy code to clipboard" title="Copy" class="clean-btn"><span class="copyButtonIcons_eSgA" aria-hidden="true"><svg viewBox="0 0 24 24" class="copyButtonIcon_y97N"><path fill="currentColor" d="M19,21H8V7H19M19,5H8A2,2 0 0,0 6,7V21A2,2 0 0,0 8,23H19A2,2 0 0,0 21,21V7A2,2 0 0,0 19,5M16,1H4A2,2 0 0,0 2,3V17H4V3H16V1Z"></path></svg><svg viewBox="0 0 24 24" class="copyButtonSuccessIcon_LjdS"><path fill="currentColor" d="M21,7L9,19L3.5,13.5L4.91,12.09L9,16.17L19.59,5.59L21,7Z"></path></svg></span></button></div></div></div></div></div></div>
<h3 class="anchor anchorWithStickyNavbar_LWe7" id="strategy-3-memory-mcp-integration">Strategy 3: Memory MCP Integration<a href="#strategy-3-memory-mcp-integration" class="hash-link" aria-label="Direct link to Strategy 3: Memory MCP Integration" title="Direct link to Strategy 3: Memory MCP Integration"></a></h3>
<p>Combine with the <a href="/goose/docs/mcp/memory-mcp">Memory MCP extension</a> for hybrid approach:</p>
<ol>
<li>Store Cognee usage patterns as memories</li>
<li>Use Memory MCP to trigger Cognee searches</li>
<li>Lower token usage than goosehints</li>
<li>More reliable than pure instruction files</li>
</ol>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="advanced-workflows">Advanced Workflows<a href="#advanced-workflows" class="hash-link" aria-label="Direct link to Advanced Workflows" title="Direct link to Advanced Workflows"></a></h2>
<h3 class="anchor anchorWithStickyNavbar_LWe7" id="developer-workflow">Developer Workflow<a href="#developer-workflow" class="hash-link" aria-label="Direct link to Developer Workflow" title="Direct link to Developer Workflow"></a></h3>
<p>For software development projects:</p>
<div class="language-bash codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#393A34;--prism-background-color:#f6f8fa"><div class="codeBlockContent_biex"><pre tabindex="0" class="prism-code language-bash codeBlock_bY9V thin-scrollbar" style="color:#393A34;background-color:#f6f8fa"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#393A34"><span class="token plain"># Start Goose with Cognee</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">goose session</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#393A34"><span class="token plain"># In Goose, analyze your codebase</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">&gt; Goose, please codify this repository and then help me understand the architecture</span><br></span></code></pre><div class="buttonGroup__atx"><button type="button" aria-label="Copy code to clipboard" title="Copy" class="clean-btn"><span class="copyButtonIcons_eSgA" aria-hidden="true"><svg viewBox="0 0 24 24" class="copyButtonIcon_y97N"><path fill="currentColor" d="M19,21H8V7H19M19,5H8A2,2 0 0,0 6,7V21A2,2 0 0,0 8,23H19A2,2 0 0,0 21,21V7A2,2 0 0,0 19,5M16,1H4A2,2 0 0,0 2,3V17H4V3H16V1Z"></path></svg><svg viewBox="0 0 24 24" class="copyButtonSuccessIcon_LjdS"><path fill="currentColor" d="M21,7L9,19L3.5,13.5L4.91,12.09L9,16.17L19.59,5.59L21,7Z"></path></svg></span></button></div></div></div>
<p>Goose will:</p>
<ol>
<li>Run <code>cognee-mcp__codify</code> on your repository</li>
<li>Build a code knowledge graph</li>
<li>Answer architecture questions using the graph</li>
</ol>
<h3 class="anchor anchorWithStickyNavbar_LWe7" id="research-workflow">Research Workflow<a href="#research-workflow" class="hash-link" aria-label="Direct link to Research Workflow" title="Direct link to Research Workflow"></a></h3>
<p>For research and documentation:</p>
<div class="language-bash codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#393A34;--prism-background-color:#f6f8fa"><div class="codeBlockContent_biex"><pre tabindex="0" class="prism-code language-bash codeBlock_bY9V thin-scrollbar" style="color:#393A34;background-color:#f6f8fa"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#393A34"><span class="token plain"># Cognify research documents</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">&gt; Goose, please cognify the contents of these research papers: paper1.pdf, paper2.pdf, paper3.pdf</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#393A34"><span class="token plain"># Later, query relationships</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">&gt; What are the connections between the methodologies in these papers?</span><br></span></code></pre><div class="buttonGroup__atx"><button type="button" aria-label="Copy code to clipboard" title="Copy" class="clean-btn"><span class="copyButtonIcons_eSgA" aria-hidden="true"><svg viewBox="0 0 24 24" class="copyButtonIcon_y97N"><path fill="currentColor" d="M19,21H8V7H19M19,5H8A2,2 0 0,0 6,7V21A2,2 0 0,0 8,23H19A2,2 0 0,0 21,21V7A2,2 0 0,0 19,5M16,1H4A2,2 0 0,0 2,3V17H4V3H16V1Z"></path></svg><svg viewBox="0 0 24 24" class="copyButtonSuccessIcon_LjdS"><path fill="currentColor" d="M21,7L9,19L3.5,13.5L4.91,12.09L9,16.17L19.59,5.59L21,7Z"></path></svg></span></button></div></div></div>
<h3 class="anchor anchorWithStickyNavbar_LWe7" id="personal-assistant-workflow">Personal Assistant Workflow<a href="#personal-assistant-workflow" class="hash-link" aria-label="Direct link to Personal Assistant Workflow" title="Direct link to Personal Assistant Workflow"></a></h3>
<p>For personal productivity:</p>
<div class="language-bash codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#393A34;--prism-background-color:#f6f8fa"><div class="codeBlockContent_biex"><pre tabindex="0" class="prism-code language-bash codeBlock_bY9V thin-scrollbar" style="color:#393A34;background-color:#f6f8fa"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#393A34"><span class="token plain"># Store preferences</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">&gt; Remember that I prefer morning meetings, work best with 2-hour focused blocks, and need 15-minute breaks between calls</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#393A34"><span class="token plain"># Query later</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">&gt; Based on my preferences, how should I structure tomorrow&#x27;s schedule?</span><br></span></code></pre><div class="buttonGroup__atx"><button type="button" aria-label="Copy code to clipboard" title="Copy" class="clean-btn"><span class="copyButtonIcons_eSgA" aria-hidden="true"><svg viewBox="0 0 24 24" class="copyButtonIcon_y97N"><path fill="currentColor" d="M19,21H8V7H19M19,5H8A2,2 0 0,0 6,7V21A2,2 0 0,0 8,23H19A2,2 0 0,0 21,21V7A2,2 0 0,0 19,5M16,1H4A2,2 0 0,0 2,3V17H4V3H16V1Z"></path></svg><svg viewBox="0 0 24 24" class="copyButtonSuccessIcon_LjdS"><path fill="currentColor" d="M21,7L9,19L3.5,13.5L4.91,12.09L9,16.17L19.59,5.59L21,7Z"></path></svg></span></button></div></div></div>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="performance-optimization">Performance Optimization<a href="#performance-optimization" class="hash-link" aria-label="Direct link to Performance Optimization" title="Direct link to Performance Optimization"></a></h2>
<h3 class="anchor anchorWithStickyNavbar_LWe7" id="server-configuration">Server Configuration<a href="#server-configuration" class="hash-link" aria-label="Direct link to Server Configuration" title="Direct link to Server Configuration"></a></h3>
<p>For optimal performance, run Cognee as a separate server:</p>
<div class="language-bash codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#393A34;--prism-background-color:#f6f8fa"><div class="codeBlockContent_biex"><pre tabindex="0" class="prism-code language-bash codeBlock_bY9V thin-scrollbar" style="color:#393A34;background-color:#f6f8fa"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#393A34"><span class="token plain"># Create optimized startup script</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">cat &gt; start-cognee-optimized.sh &lt;&lt; &#x27;EOF&#x27;</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">#!/bin/bash</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">set -e</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#393A34"><span class="token plain"># Performance settings</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">export DEBUG=false</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">export LOG_LEVEL=WARNING</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">export RATE_LIMIT_INTERVAL=30</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#393A34"><span class="token plain"># Model configuration</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">export LLM_API_KEY=${OPENAI_API_KEY}</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">export LLM_MODEL=openai/gpt-4o-mini # Faster, cheaper model</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">export EMBEDDING_API_KEY=${OPENAI_API_KEY}</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">export EMBEDDING_MODEL=openai/text-embedding-3-small # Faster embedding</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#393A34"><span class="token plain"># Server settings</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">export HOST=0.0.0.0</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">export PORT=8000</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">cd /path/to/cognee-mcp</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">uv run python src/server.py --transport sse</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">EOF</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">chmod +x start-cognee-optimized.sh</span><br></span></code></pre><div class="buttonGroup__atx"><button type="button" aria-label="Copy code to clipboard" title="Copy" class="clean-btn"><span class="copyButtonIcons_eSgA" aria-hidden="true"><svg viewBox="0 0 24 24" class="copyButtonIcon_y97N"><path fill="currentColor" d="M19,21H8V7H19M19,5H8A2,2 0 0,0 6,7V21A2,2 0 0,0 8,23H19A2,2 0 0,0 21,21V7A2,2 0 0,0 19,5M16,1H4A2,2 0 0,0 2,3V17H4V3H16V1Z"></path></svg><svg viewBox="0 0 24 24" class="copyButtonSuccessIcon_LjdS"><path fill="currentColor" d="M21,7L9,19L3.5,13.5L4.91,12.09L9,16.17L19.59,5.59L21,7Z"></path></svg></span></button></div></div></div>
<h3 class="anchor anchorWithStickyNavbar_LWe7" id="memory-management">Memory Management<a href="#memory-management" class="hash-link" aria-label="Direct link to Memory Management" title="Direct link to Memory Management"></a></h3>
<p>Monitor and manage your knowledge graph:</p>
<div class="language-bash codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#393A34;--prism-background-color:#f6f8fa"><div class="codeBlockContent_biex"><pre tabindex="0" class="prism-code language-bash codeBlock_bY9V thin-scrollbar" style="color:#393A34;background-color:#f6f8fa"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#393A34"><span class="token plain"># Check status</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">&gt; Goose, what&#x27;s the status of the cognify pipeline?</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#393A34"><span class="token plain"># Selective pruning (if needed)</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">&gt; Goose, can you help me identify outdated information in the knowledge graph?</span><br></span></code></pre><div class="buttonGroup__atx"><button type="button" aria-label="Copy code to clipboard" title="Copy" class="clean-btn"><span class="copyButtonIcons_eSgA" aria-hidden="true"><svg viewBox="0 0 24 24" class="copyButtonIcon_y97N"><path fill="currentColor" d="M19,21H8V7H19M19,5H8A2,2 0 0,0 6,7V21A2,2 0 0,0 8,23H19A2,2 0 0,0 21,21V7A2,2 0 0,0 19,5M16,1H4A2,2 0 0,0 2,3V17H4V3H16V1Z"></path></svg><svg viewBox="0 0 24 24" class="copyButtonSuccessIcon_LjdS"><path fill="currentColor" d="M21,7L9,19L3.5,13.5L4.91,12.09L9,16.17L19.59,5.59L21,7Z"></path></svg></span></button></div></div></div>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="troubleshooting">Troubleshooting<a href="#troubleshooting" class="hash-link" aria-label="Direct link to Troubleshooting" title="Direct link to Troubleshooting"></a></h2>
<h3 class="anchor anchorWithStickyNavbar_LWe7" id="common-issues">Common Issues<a href="#common-issues" class="hash-link" aria-label="Direct link to Common Issues" title="Direct link to Common Issues"></a></h3>
<ol>
<li><strong>Slow startup</strong>: Use Method 2 (separate server) configuration</li>
<li><strong>Memory not persisting</strong>: Check file permissions and paths</li>
<li><strong>Search returning empty results</strong>: Ensure data was properly cognified</li>
<li><strong>High token usage</strong>: Use instruction files instead of goosehints</li>
</ol>
<h3 class="anchor anchorWithStickyNavbar_LWe7" id="debug-commands">Debug Commands<a href="#debug-commands" class="hash-link" aria-label="Direct link to Debug Commands" title="Direct link to Debug Commands"></a></h3>
<div class="language-bash codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#393A34;--prism-background-color:#f6f8fa"><div class="codeBlockContent_biex"><pre tabindex="0" class="prism-code language-bash codeBlock_bY9V thin-scrollbar" style="color:#393A34;background-color:#f6f8fa"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#393A34"><span class="token plain"># Check Cognee logs</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">tail -f ~/.local/share/cognee/logs/cognee.log</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#393A34"><span class="token plain"># Test server connection</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">curl http://localhost:8000/health</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#393A34"><span class="token plain"># Verify knowledge graph status</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain"># In Goose session:</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">&gt; Goose, run cognify_status and codify_status</span><br></span></code></pre><div class="buttonGroup__atx"><button type="button" aria-label="Copy code to clipboard" title="Copy" class="clean-btn"><span class="copyButtonIcons_eSgA" aria-hidden="true"><svg viewBox="0 0 24 24" class="copyButtonIcon_y97N"><path fill="currentColor" d="M19,21H8V7H19M19,5H8A2,2 0 0,0 6,7V21A2,2 0 0,0 8,23H19A2,2 0 0,0 21,21V7A2,2 0 0,0 19,5M16,1H4A2,2 0 0,0 2,3V17H4V3H16V1Z"></path></svg><svg viewBox="0 0 24 24" class="copyButtonSuccessIcon_LjdS"><path fill="currentColor" d="M21,7L9,19L3.5,13.5L4.91,12.09L9,16.17L19.59,5.59L21,7Z"></path></svg></span></button></div></div></div>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="best-practices">Best Practices<a href="#best-practices" class="hash-link" aria-label="Direct link to Best Practices" title="Direct link to Best Practices"></a></h2>
<h3 class="anchor anchorWithStickyNavbar_LWe7" id="data-organization">Data Organization<a href="#data-organization" class="hash-link" aria-label="Direct link to Data Organization" title="Direct link to Data Organization"></a></h3>
<ol>
<li>
<p><strong>Use nodesets</strong> for organizing different types of information:</p>
<div class="language-bash codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#393A34;--prism-background-color:#f6f8fa"><div class="codeBlockContent_biex"><pre tabindex="0" class="prism-code language-bash codeBlock_bY9V thin-scrollbar" style="color:#393A34;background-color:#f6f8fa"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#393A34"><span class="token plain"># Developer rules</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">&gt; Goose, add these coding standards to the &#x27;developer_rules&#x27; nodeset</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#393A34"><span class="token plain"># Project-specific info </span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">&gt; Goose, cognify this project documentation with nodeset &#x27;project_alpha&#x27;</span><br></span></code></pre><div class="buttonGroup__atx"><button type="button" aria-label="Copy code to clipboard" title="Copy" class="clean-btn"><span class="copyButtonIcons_eSgA" aria-hidden="true"><svg viewBox="0 0 24 24" class="copyButtonIcon_y97N"><path fill="currentColor" d="M19,21H8V7H19M19,5H8A2,2 0 0,0 6,7V21A2,2 0 0,0 8,23H19A2,2 0 0,0 21,21V7A2,2 0 0,0 19,5M16,1H4A2,2 0 0,0 2,3V17H4V3H16V1Z"></path></svg><svg viewBox="0 0 24 24" class="copyButtonSuccessIcon_LjdS"><path fill="currentColor" d="M21,7L9,19L3.5,13.5L4.91,12.09L9,16.17L19.59,5.59L21,7Z"></path></svg></span></button></div></div></div>
</li>
<li>
<p><strong>Regular maintenance</strong>:</p>
<ul>
<li>Review and update stored information monthly</li>
<li>Remove outdated preferences and facts</li>
<li>Optimize search queries based on usage patterns</li>
</ul>
</li>
</ol>
<h3 class="anchor anchorWithStickyNavbar_LWe7" id="integration-patterns">Integration Patterns<a href="#integration-patterns" class="hash-link" aria-label="Direct link to Integration Patterns" title="Direct link to Integration Patterns"></a></h3>
<ol>
<li><strong>Layered approach</strong>: Use both Memory MCP and Cognee for different purposes</li>
<li><strong>Context switching</strong>: Different instruction files for different workflows</li>
<li><strong>Selective automation</strong>: Not every interaction needs knowledge graph queries</li>
</ol>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="examples">Examples<a href="#examples" class="hash-link" aria-label="Direct link to Examples" title="Direct link to Examples"></a></h2>
<h3 class="anchor anchorWithStickyNavbar_LWe7" id="code-review-assistant">Code Review Assistant<a href="#code-review-assistant" class="hash-link" aria-label="Direct link to Code Review Assistant" title="Direct link to Code Review Assistant"></a></h3>
<div class="language-bash codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#393A34;--prism-background-color:#f6f8fa"><div class="codeBlockContent_biex"><pre tabindex="0" class="prism-code language-bash codeBlock_bY9V thin-scrollbar" style="color:#393A34;background-color:#f6f8fa"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#393A34"><span class="token plain"># Setup</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">&gt; Goose, codify this repository and remember that I prefer: functional programming patterns, comprehensive tests, and clear documentation</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#393A34"><span class="token plain"># Usage</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">&gt; Review this pull request and check it against my coding preferences</span><br></span></code></pre><div class="buttonGroup__atx"><button type="button" aria-label="Copy code to clipboard" title="Copy" class="clean-btn"><span class="copyButtonIcons_eSgA" aria-hidden="true"><svg viewBox="0 0 24 24" class="copyButtonIcon_y97N"><path fill="currentColor" d="M19,21H8V7H19M19,5H8A2,2 0 0,0 6,7V21A2,2 0 0,0 8,23H19A2,2 0 0,0 21,21V7A2,2 0 0,0 19,5M16,1H4A2,2 0 0,0 2,3V17H4V3H16V1Z"></path></svg><svg viewBox="0 0 24 24" class="copyButtonSuccessIcon_LjdS"><path fill="currentColor" d="M21,7L9,19L3.5,13.5L4.91,12.09L9,16.17L19.59,5.59L21,7Z"></path></svg></span></button></div></div></div>
<h3 class="anchor anchorWithStickyNavbar_LWe7" id="meeting-assistant">Meeting Assistant<a href="#meeting-assistant" class="hash-link" aria-label="Direct link to Meeting Assistant" title="Direct link to Meeting Assistant"></a></h3>
<div class="language-bash codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#393A34;--prism-background-color:#f6f8fa"><div class="codeBlockContent_biex"><pre tabindex="0" class="prism-code language-bash codeBlock_bY9V thin-scrollbar" style="color:#393A34;background-color:#f6f8fa"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#393A34"><span class="token plain"># Before meeting</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">&gt; Goose, cognify the agenda and participant backgrounds from these documents</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#393A34"><span class="token plain"># During/after meeting</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">&gt; Based on the knowledge graph, what are the key action items and how do they relate to our previous discussions?</span><br></span></code></pre><div class="buttonGroup__atx"><button type="button" aria-label="Copy code to clipboard" title="Copy" class="clean-btn"><span class="copyButtonIcons_eSgA" aria-hidden="true"><svg viewBox="0 0 24 24" class="copyButtonIcon_y97N"><path fill="currentColor" d="M19,21H8V7H19M19,5H8A2,2 0 0,0 6,7V21A2,2 0 0,0 8,23H19A2,2 0 0,0 21,21V7A2,2 0 0,0 19,5M16,1H4A2,2 0 0,0 2,3V17H4V3H16V1Z"></path></svg><svg viewBox="0 0 24 24" class="copyButtonSuccessIcon_LjdS"><path fill="currentColor" d="M21,7L9,19L3.5,13.5L4.91,12.09L9,16.17L19.59,5.59L21,7Z"></path></svg></span></button></div></div></div>
<h3 class="anchor anchorWithStickyNavbar_LWe7" id="research-assistant">Research Assistant<a href="#research-assistant" class="hash-link" aria-label="Direct link to Research Assistant" title="Direct link to Research Assistant"></a></h3>
<div class="language-bash codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#393A34;--prism-background-color:#f6f8fa"><div class="codeBlockContent_biex"><pre tabindex="0" class="prism-code language-bash codeBlock_bY9V thin-scrollbar" style="color:#393A34;background-color:#f6f8fa"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#393A34"><span class="token plain"># Literature review</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">&gt; Goose, cognify these 10 research papers and create a knowledge graph of the relationships between their methodologies</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#393A34"><span class="token plain"># Synthesis</span><br></span><span class="token-line" style="color:#393A34"><span class="token plain">&gt; What are the emerging patterns in the research and what gaps exist?</span><br></span></code></pre><div class="buttonGroup__atx"><button type="button" aria-label="Copy code to clipboard" title="Copy" class="clean-btn"><span class="copyButtonIcons_eSgA" aria-hidden="true"><svg viewBox="0 0 24 24" class="copyButtonIcon_y97N"><path fill="currentColor" d="M19,21H8V7H19M19,5H8A2,2 0 0,0 6,7V21A2,2 0 0,0 8,23H19A2,2 0 0,0 21,21V7A2,2 0 0,0 19,5M16,1H4A2,2 0 0,0 2,3V17H4V3H16V1Z"></path></svg><svg viewBox="0 0 24 24" class="copyButtonSuccessIcon_LjdS"><path fill="currentColor" d="M21,7L9,19L3.5,13.5L4.91,12.09L9,16.17L19.59,5.59L21,7Z"></path></svg></span></button></div></div></div>
<p>This advanced usage guide should help you maximize the potential of Cognee with Goose for sophisticated knowledge management and automation workflows.</p></div></article><nav class="pagination-nav docusaurus-mt-lg" aria-label="Docs pages"><a class="pagination-nav__link pagination-nav__link--prev" href="/goose/docs/category/tutorials"><div class="pagination-nav__sublabel">Previous</div><div class="pagination-nav__label">Tutorials</div></a><a class="pagination-nav__link pagination-nav__link--next" href="/goose/docs/tutorials/benchmarking"><div class="pagination-nav__sublabel">Next</div><div class="pagination-nav__label">Benchmark with Goose</div></a></nav></div></div><div class="col col--3"><div class="tableOfContents_bqdL thin-scrollbar theme-doc-toc-desktop"><ul class="table-of-contents table-of-contents__left-border"><li><a href="#overview" class="table-of-contents__link toc-highlight">Overview</a></li><li><a href="#key-concepts" class="table-of-contents__link toc-highlight">Key Concepts</a><ul><li><a href="#knowledge-graph-memory" class="table-of-contents__link toc-highlight">Knowledge Graph Memory</a></li><li><a href="#search-types" class="table-of-contents__link toc-highlight">Search Types</a></li></ul></li><li><a href="#automation-strategies" class="table-of-contents__link toc-highlight">Automation Strategies</a><ul><li><a href="#instruction-files" class="table-of-contents__link toc-highlight">Instruction Files</a></li><li><a href="#goosehints-file" class="table-of-contents__link toc-highlight">Goosehints File</a></li><li><a href="#strategy-3-memory-mcp-integration" class="table-of-contents__link toc-highlight">Strategy 3: Memory MCP Integration</a></li></ul></li><li><a href="#advanced-workflows" class="table-of-contents__link toc-highlight">Advanced Workflows</a><ul><li><a href="#developer-workflow" class="table-of-contents__link toc-highlight">Developer Workflow</a></li><li><a href="#research-workflow" class="table-of-contents__link toc-highlight">Research Workflow</a></li><li><a href="#personal-assistant-workflow" class="table-of-contents__link toc-highlight">Personal Assistant Workflow</a></li></ul></li><li><a href="#performance-optimization" class="table-of-contents__link toc-highlight">Performance Optimization</a><ul><li><a href="#server-configuration" class="table-of-contents__link toc-highlight">Server Configuration</a></li><li><a href="#memory-management" class="table-of-contents__link toc-highlight">Memory Management</a></li></ul></li><li><a href="#troubleshooting" class="table-of-contents__link toc-highlight">Troubleshooting</a><ul><li><a href="#common-issues" class="table-of-contents__link toc-highlight">Common Issues</a></li><li><a href="#debug-commands" class="table-of-contents__link toc-highlight">Debug Commands</a></li></ul></li><li><a href="#best-practices" class="table-of-contents__link toc-highlight">Best Practices</a><ul><li><a href="#data-organization" class="table-of-contents__link toc-highlight">Data Organization</a></li><li><a href="#integration-patterns" class="table-of-contents__link toc-highlight">Integration Patterns</a></li></ul></li><li><a href="#examples" class="table-of-contents__link toc-highlight">Examples</a><ul><li><a href="#code-review-assistant" class="table-of-contents__link toc-highlight">Code Review Assistant</a></li><li><a href="#meeting-assistant" class="table-of-contents__link toc-highlight">Meeting Assistant</a></li><li><a href="#research-assistant" class="table-of-contents__link toc-highlight">Research Assistant</a></li></ul></li></ul></div></div></div></div></main></div></div></div><footer class="footer"><div class="container container-fluid"><div class="row footer__links"><div class="col footer__col"><div class="footer__title">Quick Links</div><ul class="footer__items clean-list"><li class="footer__item"><a class="footer__link-item" href="/goose/docs/getting-started/installation">Install Goose</a></li><li class="footer__item"><a class="footer__link-item" href="/goose/extensions">Extensions</a></li></ul></div><div class="col footer__col"><div class="footer__title">Community</div><ul class="footer__items clean-list"><li class="footer__item"><a class="footer__link-item" href="/goose/community">Spotlight</a></li><li class="footer__item"><a href="https://discord.gg/block-opensource" target="_blank" rel="noopener noreferrer" class="footer__link-item">Discord<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_nPIU"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a></li><li class="footer__item"><a href="https://www.youtube.com/@blockopensource" target="_blank" rel="noopener noreferrer" class="footer__link-item">YouTube<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_nPIU"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a></li><li class="footer__item"><a href="https://www.linkedin.com/company/block-opensource" target="_blank" rel="noopener noreferrer" class="footer__link-item">LinkedIn<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_nPIU"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a></li><li class="footer__item"><a href="https://x.com/blockopensource" target="_blank" rel="noopener noreferrer" class="footer__link-item">Twitter / X<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_nPIU"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a></li><li class="footer__item"><a href="https://bsky.app/profile/opensource.block.xyz" target="_blank" rel="noopener noreferrer" class="footer__link-item">BlueSky<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_nPIU"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a></li><li class="footer__item"><a href="https://njump.me/opensource@block.xyz" target="_blank" rel="noopener noreferrer" class="footer__link-item">Nostr<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_nPIU"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a></li></ul></div><div class="col footer__col"><div class="footer__title">More</div><ul class="footer__items clean-list"><li class="footer__item"><a class="footer__link-item" href="/goose/blog">Blog</a></li><li class="footer__item"><a href="https://github.com/block/goose" target="_blank" rel="noopener noreferrer" class="footer__link-item">GitHub<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_nPIU"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a></li></ul></div></div><div class="footer__bottom text--center"><div class="footer__copyright">Copyright © 2025 Block, Inc.</div></div></div></footer></div>
<script src="/goose/inkeepChatButton.js" type="module"></script>
<div id="inkeepSearchBar"></div>
<script>(()=>{const e=document.getElementById("inkeepSearchBar");new MutationObserver((t=>{const n=document.getElementById("inkeep");n&&n.appendChild(e)})).observe(document.documentElement,{attributes:!0})})()</script>
<script src="/goose/inkeepSearchBar.js" type="module"></script></body>
</html>