Git-Native Agent Definition Format (agent.yaml + SOUL/RULES/MEMORY)

gitagent ยท ai, agent-config, version-control, yaml-schema, agent-forking, dev-tools

Agent identity, rules, memory, tools, skills, and hooks are all version-controlled files, so agents can be forked, branched, and diffed. Strong convergence with the OMC agent catalog โ€” worth aligning formats rather than maintaining two.

// Source: https://github.com/mperkins0155/gitagent | License: MIT | Copyright 2025 GitAgent Contributors
// Provided via justclaw.it.com; keep this notice with the code.
import { readFile, readdir, stat } from "fs/promises";
import { join } from "path";
import yaml from "js-yaml";

export interface SubAgentMetadata {
	name: string;
	description: string;
	type: "directory" | "file";
	path: string;
}

function parseFrontmatter(content: string): { frontmatter: Record<string, any>; body: string } {
	const match = content.match(/^---\r?\n([\s\S]*?)\r?\n---\r?\n?([\s\S]*)$/);
	if (!match) {
		return { frontmatter: {}, body: content };
	}
	const frontmatter = yaml.load(match[1]) as Record<string, any>;
	return { frontmatter, body: match[2] };
}

export async function discoverSubAgents(agentDir: 

... (truncated -- full source via MCP)

See the full source, get the GitHub permalink, and search 40K more like it.

Get a free API key