https://www.boundaryml.com logo
Context Tricks
# general
b
@blackl1ght let’s chat about knowledge / context management with CC!
b
Context Management w/ Claude Code
btw @dexlayer codelayer general availability when
b
So I was really curious what your frontmatter in your docs looks like and how you instruct the structure into it
b
yeah so this is something I just picked up from Dex's public prompts
here's a snippet of my tweaked
create_implementation_plan.md
doc: ### Step 3: Gather Metadata and Write Implementation Plan 1. Gather metadata for the implementation strategy document: - Run the
scripts/spec_metadata.sh
script to generate all relevant metadata - Filename: should be under the
specifications
directory for the feature that you're currently working on, e.g.
specifications/01-better-session-support/implementation-plan.md
, or under
specifications/general
if you don't have information about which feature you're working on. Name the file
implementation-plan.md
2. Generate implementation strategy document: - Use the metadata gathered in step 1 - Structure the document with YAML frontmatter followed by content:
Copy code
markdown

     ---
     date: [Current date and time with timezone in ISO format]
     researcher: [Researcher name from thoughts status]
     git_commit: [Current commit hash]
     branch: [Current branch name]
     repository: [Repository name]
     topic: "[Feature/Task Name] Implementation Strategy"
     tags: [implementation, strategy, relevant-component-names]
     status: complete
     last_updated: [Current date in YYYY-MM-DD format]
     last_updated_by: [Researcher name]
     type: implementation_strategy
     ---
hmm the formatting didn't carry over well
this is the shell script:
Copy code
shell
#!/usr/bin/env bash
set -euo pipefail

# Collect metadata
DATETIME_TZ=$(date '+%Y-%m-%d %H:%M:%S %Z')
FILENAME_TS=$(date '+%Y-%m-%d_%H-%M-%S')

if command -v git >/dev/null 2>&1 && git rev-parse --is-inside-work-tree >/dev/null 2>&1; then
  REPO_ROOT=$(git rev-parse --show-toplevel)
  REPO_NAME=$(basename "$REPO_ROOT")
  GIT_BRANCH=$(git branch --show-current 2>/dev/null || git rev-parse --abbrev-ref HEAD)
  GIT_COMMIT=$(git rev-parse HEAD)
else
  REPO_ROOT=""
  REPO_NAME=""
  GIT_BRANCH=""
  GIT_COMMIT=""
fi

# Optional: thoughts system status (may be long). Limit lines to avoid noise.
THOUGHTS_STATUS=""
if command -v humanlayer >/dev/null 2>&1; then
  # Capture first 40 lines; adjust as needed.
  THOUGHTS_STATUS=$(humanlayer thoughts status 2>/dev/null | head -n 40)
fi

# Print similar to the individual command outputs
echo "Current Date/Time (TZ): $DATETIME_TZ"
[ -n "$GIT_COMMIT" ] && echo "Current Git Commit Hash: $GIT_COMMIT"
[ -n "$GIT_BRANCH" ] && echo "Current Branch Name: $GIT_BRANCH"
[ -n "$REPO_NAME" ] && echo "Repository Name: $REPO_NAME"
echo "Timestamp For Filename: $FILENAME_TS"
[ -n "$THOUGHTS_STATUS" ] && {
  echo "$THOUGHTS_STATUS"
}
and here's an example of the generated frontmatter:
Copy code
markdown
---
date: 2025-07-29T20:55:24-05:00
researcher: Kyle Mistele
git_commit: 5bc7c239881ace5c7b067f5684cd0b5694df2a3d
branch: master
repository: mcplatform
topic: "Sub-Feature: Server Assignment & Configuration UI"
tags: [sub-feature-definition, interactive-walkthrough, server-assignment, configuration]
status: complete
last_updated: 2025-07-29
last_updated_by: Claude
type: sub_feature_definition
---

# Sub-Feature: Server Assignment & Configuration UI
d
b
using Vaibhav's multi agent prompt trick and wow it's nice input:
> Make a todo task list for yourself and use subagents to conduct research. Put your findings in docs/specs/001-smoketest-research.md
https://cdn.discordapp.com/attachments/1402343594890629171/1402740650130280488/image.png?ex=68950388&is=6893b208&hm=b8ebaf4361440d5eb9f9142530e52c739c0177c892feb9ccada1ecdccdc03063&
d
haha it can be Vaibhav's prompt trick after he's tried it as least once πŸ˜‰ this prompt was the result of 6-8 of iterating on https://github.com/humanlayer/humanlayer though
d
awesome!
b
d
holy shit you even enabled brainrot mode! https://x.com/dexhorthy/status/1954225964004921364
your tmux (?) config looks dope btw
b
Thanks! I have three different layouts (Zellij) looking at the same set of tmux panes so I can supervise the same 3 agents from my phone, tablet, and desktop/laptop without the session termination being an issue
2 Views