content-generator
Skill2 starsChanged 38 days agoMITView on GitHub
Use when a note has only a title and needs comprehensive AI-generated content, optionally enriched with web research context
In this repository15 other files it gives its agents.
- notemdproSkill
- batch-processorSkill
- concept-extractorSkill
- diagram-generatorSkill
- formula-healerSkill
- link-analyzerSkill
- mermaid-healerSkill
- mermaid-summarizerSkill
- qa-extractorSkill
- selection-processorSkill
- system-architectureSkill
- test-driven-developmentSkill
- text-translatorSkill
- web-researcherSkill
- workflow-runnerSkill
The file
We split this skill into the rules it gives an agent
1 rule. About 0 are common, 1 is distinctive, and 0 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈1
Distinctive · estimate
This author's own choices. Worth a look.
0
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 147
After LLM generates content, the following fixes are automatically applied:
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
NoteMD Pro - Generate Content from Title
Overview
This feature generates comprehensive content for a note based solely on its title. It can optionally perform web research first, then generates detailed documentation including explanations, tables, equations (LaTeX), and Mermaid diagrams.
When to Use
- Create new notes: Generate detailed content from a title
- Expand outlines: Turn brief titles into full documents
- Research summaries: Get comprehensive overviews with web context
- Technical docs: Generate scientific/technical documentation
Function Call Chain
generateContentForTitle (fileUtils.ts)
├── getProviderForTask('generateTitle', settings)
├── _performResearch(app, settings, title, reporter) [IF enabled]
│ ├── SearchManager.getProvider
│ ├── provider.search(query)
│ └── fetchContentFromUrl(url)
├── call[Provider]API(prompt, title + researchContext)
├── cleanupLatexDelimiters(content)
├── refineMermaidBlocks(content) ← AUTO-FIX
└── fixMermaidSyntaxInFile(outputPath, reporter) ← AUTO-RUN AFTER LLM
└── checkMermaidErrors(content)Key Functions (from fileUtils.ts)
generateContentForTitle
Generates content for a note based on its title using LLM.
export async function generateContentForTitle(
settings: NotemdSettings,
inputPath: string,
progressReporter: ProgressReporter,
);batchGenerateContentForTitles
Batch generates content for all markdown files in a folder.
export async function batchGenerateContentForTitles(
settings: NotemdSettings,
folderPath: string,
progressReporter: ProgressReporter,
);
// Flow:
// 1. Get all .md files in folder
// 2. Create "complete" output folder
// 3. Process files (serial or parallel based on settings)
// 4. Move processed files to complete folderfixMermaidSyntaxInFile
Fixes Mermaid syntax in a file (auto-run after generation).
export async function fixMermaidSyntaxInFile(
filePath: string,
reporter: ProgressReporter,
): Promise<boolean>;Settings
Research Settings
| Setting | Description |
enableResearchInGenerateContent | Enable web research before generation |
searchProvider | 'tavily' or 'duckduckgo' |
tavilyApiKey | API key for Tavily |
maxResearchContentTokens | Max tokens for research context |
tavilyMaxResults | Number of Tavily results |
ddgMaxResults | Number of DuckDuckGo results |
Contextual Context (Macro Settings)
| Setting | Description |
enableFocusedLearning | Inject macro user domain preferences globally |
focusedLearningDomain | The specific domain context (e.g., "Computer Graphics", "Biochemistry") |
Output Settings
| Setting | Description |
useCustomGenerateTitleOutputFolder | Use custom output folder |
generateTitleOutputFolderName | Custom folder name (default: "_complete") |
Language Settings
| Setting | Description |
language | Target language code |
useDifferentLanguagesForTasks | Per-task language selection |
generateTitleLanguage | Language for title generation |
Prompt Template (generateTitle)
From promptUtils.ts:
Create comprehensive technical documentation about "{TITLE}" with a focus on
scientific and mathematical rigor.
{RESEARCH_CONTEXT_SECTION}
Include:
1. Detailed explanation of core concepts with their mathematical foundations.
Start with a Level 2 Header (## {TITLE}).
2. Key technical specifications with precise values and units (use tables).
3. Common use cases with quantitative performance metrics.
4. Implementation considerations with algorithmic complexity analysis.
5. Performance characteristics with statistical measures.
6. Related technologies with comparative mathematical models.
7. Mathematical equations in LaTeX format (using $$...$$ for display and
$...$ for inline) with detailed explanations.
8. Mermaid.js diagram code blocks using the format ```mermaid ... ```
IMPORTANT: without brackets "()" or "{}" for Mermaid diagrams.
Enclosed node names with spaces/special characters in square brackets [ and ].
Avoids special LaTeX syntax and Added quotes around subgraph titles.
"subgraph" and "end" cannot appear on the same line!
9. Use bullet points for lists longer than 3 items.
10. Include references to academic papers with DOI where applicable.
11. Preserve all mathematical formulas and scientific principles.
12. Define all variables and parameters used in equations.
Format directly for Obsidian markdown. Do NOT wrap the entire response in
a markdown code block. Start directly with the Level 2 Header.Auto-Fix After Generation
After LLM generates content, the following fixes are automatically applied:
- cleanupLatexDelimiters:
- Converts
\( \)to$ - Removes extra whitespace in math expressions
- Protects display math
$$...$$
- Converts
- refineMermaidBlocks:
- Fixes unquoted labels
- Closes unclosed blocks
- Applies 20+ fix patterns
- fixMermaidSyntaxInFile (auto-run):
- Validates Mermaid syntax using
mermaid.parse - Applies deep debug fixes if errors found
- Logs validation results
- Validates Mermaid syntax using
See mermaid-healer for full Mermaid fixing code.
Error Handling
Common Errors
- No research context
- Warning: "Research for 'title' returned no results"
- Solution: Check API keys, network connection
- Mermaid syntax errors
- Warning: "Mermaid errors found after generation"
- Solution: Auto-fix applied, check logs
- Content too long
- Error: Max tokens exceeded
- Solution: Reduce research context or chunk size
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

