[{"data":1,"prerenderedAt":611},["ShallowReactive",2],{"doc-seo-\u002Fdocs\u002Fguide\u002Fclients":3,"content-query-B3MYHU1JWH":6},{"title":4,"description":5},"Client Setup & Hooks","Connect Strata to Antigravity, Claude Code, Codex, OpenCode, or any MCP client, and configure post-write index sync hooks.",{"_path":7,"_dir":8,"_draft":9,"_partial":9,"_locale":10,"title":4,"description":5,"badge":11,"body":12,"_type":605,"_id":606,"_source":607,"_file":608,"_stem":609,"_extension":610},"\u002Fdocs\u002Fguide\u002Fclients","guide",false,"","Guide",{"type":13,"children":14,"toc":598},"root",[15,32,39,188,195,384,389,395,400,516,522,551,592],{"type":16,"tag":17,"props":18,"children":19},"element","p",{},[20,23,30],{"type":21,"value":22},"text","You can set up Strata automatically with ",{"type":16,"tag":24,"props":25,"children":27},"code",{"className":26},[],[28],{"type":21,"value":29},"strata init --harness \u003Cname>",{"type":21,"value":31}," or add it manually to your MCP client's JSON\u002FTOML configuration.",{"type":16,"tag":33,"props":34,"children":36},"h2",{"id":35},"automatic-setup-by-client",[37],{"type":21,"value":38},"Automatic Setup by Client",{"type":16,"tag":40,"props":41,"children":45},"pre",{"className":42,"code":43,"language":44,"meta":10,"style":10},"language-bash shiki shiki-themes github-light github-dark","strata init --harness antigravity   # Google Antigravity (.agents\u002F)\nstrata init --harness claude        # Claude Code (.claude\u002F + .mcp.json)\nstrata init --harness codex         # OpenAI Codex CLI (.codex\u002F)\nstrata init --harness opencode      # OpenCode (opencode.json + .opencode\u002Fplugin\u002F)\nstrata init --harness agents        # Universal agent harness (.agents\u002F)\n","bash",[46],{"type":16,"tag":24,"props":47,"children":48},{"__ignoreMap":10},[49,84,110,136,162],{"type":16,"tag":50,"props":51,"children":54},"span",{"class":52,"line":53},"line",1,[55,61,67,73,78],{"type":16,"tag":50,"props":56,"children":58},{"style":57},"--shiki-default:#6F42C1;--shiki-dark:#B392F0",[59],{"type":21,"value":60},"strata",{"type":16,"tag":50,"props":62,"children":64},{"style":63},"--shiki-default:#032F62;--shiki-dark:#9ECBFF",[65],{"type":21,"value":66}," init",{"type":16,"tag":50,"props":68,"children":70},{"style":69},"--shiki-default:#005CC5;--shiki-dark:#79B8FF",[71],{"type":21,"value":72}," --harness",{"type":16,"tag":50,"props":74,"children":75},{"style":63},[76],{"type":21,"value":77}," antigravity",{"type":16,"tag":50,"props":79,"children":81},{"style":80},"--shiki-default:#6A737D;--shiki-dark:#6A737D",[82],{"type":21,"value":83},"   # Google Antigravity (.agents\u002F)\n",{"type":16,"tag":50,"props":85,"children":87},{"class":52,"line":86},2,[88,92,96,100,105],{"type":16,"tag":50,"props":89,"children":90},{"style":57},[91],{"type":21,"value":60},{"type":16,"tag":50,"props":93,"children":94},{"style":63},[95],{"type":21,"value":66},{"type":16,"tag":50,"props":97,"children":98},{"style":69},[99],{"type":21,"value":72},{"type":16,"tag":50,"props":101,"children":102},{"style":63},[103],{"type":21,"value":104}," claude",{"type":16,"tag":50,"props":106,"children":107},{"style":80},[108],{"type":21,"value":109},"        # Claude Code (.claude\u002F + .mcp.json)\n",{"type":16,"tag":50,"props":111,"children":113},{"class":52,"line":112},3,[114,118,122,126,131],{"type":16,"tag":50,"props":115,"children":116},{"style":57},[117],{"type":21,"value":60},{"type":16,"tag":50,"props":119,"children":120},{"style":63},[121],{"type":21,"value":66},{"type":16,"tag":50,"props":123,"children":124},{"style":69},[125],{"type":21,"value":72},{"type":16,"tag":50,"props":127,"children":128},{"style":63},[129],{"type":21,"value":130}," codex",{"type":16,"tag":50,"props":132,"children":133},{"style":80},[134],{"type":21,"value":135},"         # OpenAI Codex CLI (.codex\u002F)\n",{"type":16,"tag":50,"props":137,"children":139},{"class":52,"line":138},4,[140,144,148,152,157],{"type":16,"tag":50,"props":141,"children":142},{"style":57},[143],{"type":21,"value":60},{"type":16,"tag":50,"props":145,"children":146},{"style":63},[147],{"type":21,"value":66},{"type":16,"tag":50,"props":149,"children":150},{"style":69},[151],{"type":21,"value":72},{"type":16,"tag":50,"props":153,"children":154},{"style":63},[155],{"type":21,"value":156}," opencode",{"type":16,"tag":50,"props":158,"children":159},{"style":80},[160],{"type":21,"value":161},"      # OpenCode (opencode.json + .opencode\u002Fplugin\u002F)\n",{"type":16,"tag":50,"props":163,"children":165},{"class":52,"line":164},5,[166,170,174,178,183],{"type":16,"tag":50,"props":167,"children":168},{"style":57},[169],{"type":21,"value":60},{"type":16,"tag":50,"props":171,"children":172},{"style":63},[173],{"type":21,"value":66},{"type":16,"tag":50,"props":175,"children":176},{"style":69},[177],{"type":21,"value":72},{"type":16,"tag":50,"props":179,"children":180},{"style":63},[181],{"type":21,"value":182}," agents",{"type":16,"tag":50,"props":184,"children":185},{"style":80},[186],{"type":21,"value":187},"        # Universal agent harness (.agents\u002F)\n",{"type":16,"tag":189,"props":190,"children":192},"h3",{"id":191},"what-each-harness-generates",[193],{"type":21,"value":194},"What Each Harness Generates",{"type":16,"tag":196,"props":197,"children":198},"ul",{},[199,271,312,352],{"type":16,"tag":200,"props":201,"children":202},"li",{},[203,215,217,223,225,231,232,238,239,245,247,253,255,261,263,269],{"type":16,"tag":204,"props":205,"children":206},"strong",{},[207,209],{"type":21,"value":208},"Antigravity & ",{"type":16,"tag":24,"props":210,"children":212},{"className":211},[],[213],{"type":21,"value":214},".agents",{"type":21,"value":216},": Creates ",{"type":16,"tag":24,"props":218,"children":220},{"className":219},[],[221],{"type":21,"value":222},".agents\u002Fhooks.json",{"type":21,"value":224},", ",{"type":16,"tag":24,"props":226,"children":228},{"className":227},[],[229],{"type":21,"value":230},".agents\u002Fhooks\u002Fstrata-post-write.sh",{"type":21,"value":224},{"type":16,"tag":24,"props":233,"children":235},{"className":234},[],[236],{"type":21,"value":237},".agents\u002Frules\u002Fstrata-frontend.md",{"type":21,"value":224},{"type":16,"tag":24,"props":240,"children":242},{"className":241},[],[243],{"type":21,"value":244},".agents\u002Fskills\u002Fuse-strata\u002FSKILL.md",{"type":21,"value":246},", and ",{"type":16,"tag":24,"props":248,"children":250},{"className":249},[],[251],{"type":21,"value":252},".agents\u002Fmcp.json",{"type":21,"value":254},". Because Antigravity loads MCP servers globally, ",{"type":16,"tag":24,"props":256,"children":258},{"className":257},[],[259],{"type":21,"value":260},"strata init",{"type":21,"value":262}," also prints the exact snippet to add to ",{"type":16,"tag":24,"props":264,"children":266},{"className":265},[],[267],{"type":21,"value":268},"~\u002F.gemini\u002Fantigravity\u002Fmcp_config.json",{"type":21,"value":270},".",{"type":16,"tag":200,"props":272,"children":273},{},[274,279,281,287,289,295,297,303,305,311],{"type":16,"tag":204,"props":275,"children":276},{},[277],{"type":21,"value":278},"Claude Code",{"type":21,"value":280},": Updates ",{"type":16,"tag":24,"props":282,"children":284},{"className":283},[],[285],{"type":21,"value":286},".claude\u002Fsettings.json",{"type":21,"value":288}," with a ",{"type":16,"tag":24,"props":290,"children":292},{"className":291},[],[293],{"type":21,"value":294},"PostToolUse",{"type":21,"value":296}," hook, writes ",{"type":16,"tag":24,"props":298,"children":300},{"className":299},[],[301],{"type":21,"value":302},".claude\u002Fhooks\u002Fstrata-post-write.sh",{"type":21,"value":304},", and adds Strata to ",{"type":16,"tag":24,"props":306,"children":308},{"className":307},[],[309],{"type":21,"value":310},".mcp.json",{"type":21,"value":270},{"type":16,"tag":200,"props":313,"children":314},{},[315,320,321,327,329,335,337,343,345,351],{"type":16,"tag":204,"props":316,"children":317},{},[318],{"type":21,"value":319},"OpenAI Codex CLI",{"type":21,"value":280},{"type":16,"tag":24,"props":322,"children":324},{"className":323},[],[325],{"type":21,"value":326},".codex\u002Fhooks.json",{"type":21,"value":328},", writes ",{"type":16,"tag":24,"props":330,"children":332},{"className":331},[],[333],{"type":21,"value":334},".codex\u002Fhooks\u002Fstrata-post-write.sh",{"type":21,"value":336},", and configures ",{"type":16,"tag":24,"props":338,"children":340},{"className":339},[],[341],{"type":21,"value":342},"[mcp_servers.strata]",{"type":21,"value":344}," in ",{"type":16,"tag":24,"props":346,"children":348},{"className":347},[],[349],{"type":21,"value":350},".codex\u002Fconfig.toml",{"type":21,"value":270},{"type":16,"tag":200,"props":353,"children":354},{},[355,360,361,367,369,375,377,383],{"type":16,"tag":204,"props":356,"children":357},{},[358],{"type":21,"value":359},"OpenCode",{"type":21,"value":280},{"type":16,"tag":24,"props":362,"children":364},{"className":363},[],[365],{"type":21,"value":366},"opencode.json",{"type":21,"value":368}," (",{"type":16,"tag":24,"props":370,"children":372},{"className":371},[],[373],{"type":21,"value":374},"mcp.strata",{"type":21,"value":376},") and installs ",{"type":16,"tag":24,"props":378,"children":380},{"className":379},[],[381],{"type":21,"value":382},".opencode\u002Fplugin\u002Fstrata-autosync.ts",{"type":21,"value":270},{"type":16,"tag":17,"props":385,"children":386},{},[387],{"type":21,"value":388},"Existing user hooks and malformed config files are left untouched during initialization.",{"type":16,"tag":33,"props":390,"children":392},{"id":391},"manual-mcp-configuration",[393],{"type":21,"value":394},"Manual MCP Configuration",{"type":16,"tag":17,"props":396,"children":397},{},[398],{"type":21,"value":399},"Add Strata to any standard MCP client config:",{"type":16,"tag":40,"props":401,"children":405},{"className":402,"code":403,"language":404,"meta":10,"style":10},"language-json shiki shiki-themes github-light github-dark","{\n  \"mcpServers\": {\n    \"strata\": {\n      \"command\": \"strata\",\n      \"args\": [\"serve\"]\n    }\n  }\n}\n","json",[406],{"type":16,"tag":24,"props":407,"children":408},{"__ignoreMap":10},[409,418,431,443,466,489,498,507],{"type":16,"tag":50,"props":410,"children":411},{"class":52,"line":53},[412],{"type":16,"tag":50,"props":413,"children":415},{"style":414},"--shiki-default:#24292E;--shiki-dark:#E1E4E8",[416],{"type":21,"value":417},"{\n",{"type":16,"tag":50,"props":419,"children":420},{"class":52,"line":86},[421,426],{"type":16,"tag":50,"props":422,"children":423},{"style":69},[424],{"type":21,"value":425},"  \"mcpServers\"",{"type":16,"tag":50,"props":427,"children":428},{"style":414},[429],{"type":21,"value":430},": {\n",{"type":16,"tag":50,"props":432,"children":433},{"class":52,"line":112},[434,439],{"type":16,"tag":50,"props":435,"children":436},{"style":69},[437],{"type":21,"value":438},"    \"strata\"",{"type":16,"tag":50,"props":440,"children":441},{"style":414},[442],{"type":21,"value":430},{"type":16,"tag":50,"props":444,"children":445},{"class":52,"line":138},[446,451,456,461],{"type":16,"tag":50,"props":447,"children":448},{"style":69},[449],{"type":21,"value":450},"      \"command\"",{"type":16,"tag":50,"props":452,"children":453},{"style":414},[454],{"type":21,"value":455},": ",{"type":16,"tag":50,"props":457,"children":458},{"style":63},[459],{"type":21,"value":460},"\"strata\"",{"type":16,"tag":50,"props":462,"children":463},{"style":414},[464],{"type":21,"value":465},",\n",{"type":16,"tag":50,"props":467,"children":468},{"class":52,"line":164},[469,474,479,484],{"type":16,"tag":50,"props":470,"children":471},{"style":69},[472],{"type":21,"value":473},"      \"args\"",{"type":16,"tag":50,"props":475,"children":476},{"style":414},[477],{"type":21,"value":478},": [",{"type":16,"tag":50,"props":480,"children":481},{"style":63},[482],{"type":21,"value":483},"\"serve\"",{"type":16,"tag":50,"props":485,"children":486},{"style":414},[487],{"type":21,"value":488},"]\n",{"type":16,"tag":50,"props":490,"children":492},{"class":52,"line":491},6,[493],{"type":16,"tag":50,"props":494,"children":495},{"style":414},[496],{"type":21,"value":497},"    }\n",{"type":16,"tag":50,"props":499,"children":501},{"class":52,"line":500},7,[502],{"type":16,"tag":50,"props":503,"children":504},{"style":414},[505],{"type":21,"value":506},"  }\n",{"type":16,"tag":50,"props":508,"children":510},{"class":52,"line":509},8,[511],{"type":16,"tag":50,"props":512,"children":513},{"style":414},[514],{"type":21,"value":515},"}\n",{"type":16,"tag":33,"props":517,"children":519},{"id":518},"how-post-write-hooks-work",[520],{"type":21,"value":521},"How Post-Write Hooks Work",{"type":16,"tag":17,"props":523,"children":524},{},[525,527,533,535,541,543,549],{"type":21,"value":526},"When an AI agent edits a frontend file, ",{"type":16,"tag":24,"props":528,"children":530},{"className":529},[],[531],{"type":21,"value":532},"strata-post-write.sh",{"type":21,"value":534}," checks whether the file extension is indexed and triggers a background ",{"type":16,"tag":24,"props":536,"children":538},{"className":537},[],[539],{"type":21,"value":540},"strata sync",{"type":21,"value":542}," using a lockfile (",{"type":16,"tag":24,"props":544,"children":546},{"className":545},[],[547],{"type":21,"value":548},".strata\u002Fsync.lock",{"type":21,"value":550},") so rapid bursts of edits coalesce cleanly.",{"type":16,"tag":196,"props":552,"children":553},{},[554,566,587],{"type":16,"tag":200,"props":555,"children":556},{},[557,559,564],{"type":21,"value":558},"Hook failures are ",{"type":16,"tag":204,"props":560,"children":561},{},[562],{"type":21,"value":563},"non-blocking",{"type":21,"value":565}," — they never stop the agent from finishing an edit.",{"type":16,"tag":200,"props":567,"children":568},{},[569,571,577,579,585],{"type":21,"value":570},"Hook activity is written to ",{"type":16,"tag":24,"props":572,"children":574},{"className":573},[],[575],{"type":21,"value":576},".strata\u002Fhook.log",{"type":21,"value":578}," (never ",{"type":16,"tag":24,"props":580,"children":582},{"className":581},[],[583],{"type":21,"value":584},"stdout",{"type":21,"value":586},", so it will not corrupt client JSON output).",{"type":16,"tag":200,"props":588,"children":589},{},[590],{"type":21,"value":591},"Even without hooks, Strata automatically checks for file changes before running indexed queries.",{"type":16,"tag":593,"props":594,"children":595},"style",{},[596],{"type":21,"value":597},"html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}",{"title":10,"searchDepth":112,"depth":112,"links":599},[600,603,604],{"id":35,"depth":86,"text":38,"children":601},[602],{"id":191,"depth":112,"text":194},{"id":391,"depth":86,"text":394},{"id":518,"depth":86,"text":521},"markdown","content:docs:guide:clients.md","content","docs\u002Fguide\u002Fclients.md","docs\u002Fguide\u002Fclients","md",1795576105519]