-
Notifications
You must be signed in to change notification settings - Fork 9
Kdf/auto issues #572
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Kdf/auto issues #572
Conversation
…orkflow
- Add AI_AGENT_REFERENCE_GUIDE.md explaining auto-generation principles
- Update auto-PR scripts to follow proper build process
- Ensure auto-generated files (index.mdx, filepathSlugs.json) are not committed
- Add build validation to workflow
- Include detailed documentation structure requirements
- Add proper {{label}} attribute requirements for script parsing
Major improvements to the auto-documentation generation process:
SYNC SCRIPT ENHANCEMENTS:
• Extract JSON code blocks from PR descriptions automatically
• Parse request parameters and types from real examples
• Derive method information from actual implementation code
• Generate structured issue content with parameter details
• Handle template variables ({{userpass}}) in JSON examples
AUTO-PR SCRIPT ENHANCEMENTS:
• Parse structured method information from enhanced issues
• Use real parameter examples in generated documentation
• Include extracted parameter details in documentation
• Generate realistic request examples from source PR data
• Improved template with actual method descriptions
WORKFLOW IMPROVEMENTS:
• End-to-end validation with build test integration
• Proper {{label}} attribute handling for script parsing
• CompactTable component integration for API documentation
• Enhanced AI prompts with structured information context
EXAMPLE WITH PR #2587:
• Automatically extracts consolidate_utxos method details
• Parses coin and merge_conditions parameters with types
• Generates documentation with real JSON examples
• Includes parameter structure: merge_at (integer), max_merge_at_once (integer)
This addresses the need to capture actual code examples from PRs like
komodo-defi-framework#2587 and use them to generate accurate API documentation
instead of generic templates.
initial workflow for AI generated drafts
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR introduces a comprehensive automated documentation workflow system that bridges the Komodo DeFi Framework (KDF) repository with the documentation repository, creating a two-stage automation pipeline for documentation updates.
Key changes:
- Automated issue creation from KDF PRs labeled "status: pending docs"
- Automated PR creation from issues labeled "ai-draft-pr"
- New
consolidate_utxosRPC method documentation with examples and usage guide
Reviewed Changes
Copilot reviewed 11 out of 12 changed files in this pull request and generated 9 comments.
Show a summary per file
| File | Description |
|---|---|
src/pages/komodo-defi-framework/changelog/index.mdx |
Added v2.6.0-beta changelog entry documenting the new UTXO consolidation feature |
src/pages/komodo-defi-framework/api/legacy/consolidate_utxos/index.mdx |
Complete documentation for the new consolidate_utxos RPC method including parameters, responses, and examples |
src/pages/komodo-defi-framework/api/index.mdx |
Added consolidate_utxos method to the main API methods table |
src/data/sidebar.json |
Added navigation entry for the new consolidate_utxos documentation page |
AI_AGENT_REFERENCE_GUIDE.md |
Comprehensive guide for AI agents documenting KDF API methods, including file structure requirements and build process |
.github/workflows/scan_kdf_pulls_clean.yml |
Workflow that scans KDF PRs daily and creates documentation issues with AI-enhanced summaries |
.github/workflows/auto-pr-from-issues.yml |
Workflow that processes labeled issues and automatically creates PRs with generated documentation |
.github/scripts/sync-docs-issues.js |
Core logic for scanning KDF PRs, extracting method information, and creating documentation issues |
.github/scripts/auto-pr-from-issues.js |
Core logic for parsing issues, generating documentation files, and creating pull requests |
.github/package.json |
Node.js dependencies for the automation workflows (Octokit, retry/throttling plugins, node-fetch) |
.github/package-lock.json |
Locked dependency versions ensuring consistent workflow execution |
.github/AUTO_PR_WORKFLOW.md |
Documentation explaining the auto-PR workflow, configuration, and usage patterns |
Files not reviewed (1)
- .github/package-lock.json: Language not supported
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-authored-by: Copilot <[email protected]>
Co-authored-by: Copilot <[email protected]>
Co-authored-by: Copilot <[email protected]>
Example issues created from this workflow: https://github.com/KomodoPlatform/komodo-docs-mdx/issues?q=is%3Aissue%20state%3Aopen%20label%3Aauto-generated
Source KDF PR: GLEECBTC/komodo-defi-framework#2587
AI generated drafts initial implementation: #574
AI generated drafts enhancements issue: #592
Generated doc for
consolidate_utxos: https://github.com/KomodoPlatform/komodo-docs-mdx/blob/598859a8fbd734e7e7e8150554e8589193b2ccc1/src/pages/komodo-defi-framework/api/legacy/consolidate_utxos/index.mdx🤖 Automated Documentation Issue Creation from KDF PRs
This PR introduces an automated workflow that monitors the
komodo-defi-frameworkrepository for PRs labeled with"status: pending docs"and automatically creates corresponding documentation issues in this repository.🎯 What This Solves
🚀 Key Features
📅 Automated Scheduling
"status: pending docs"label🎛️ Manual Control
🤖 AI-Enhanced Summaries (Optional)
🛡️ Production-Ready Features
📋 Generated Issues Include
Each created documentation issue contains:
docs-neededandauto-generatedfor organization🔧 Implementation Details
Architecture
.github/workflows/scan_kdf_pulls_clean.yml.github/scripts/sync-docs-issues.jsConfiguration
KomodoPlatform/komodo-defi-frameworkKomodoPlatform/komodo-docs-mdx"status: pending docs"["docs-needed", "auto-generated"]Setup Requirements
GITHUB_TOKENOPENAI_API_KEYsecret for AI summaries (~$1-5/month)🧪 Testing & Validation
The workflow includes comprehensive testing capabilities:
📊 Expected Impact
For Documentation Team
For Development Team
🔒 Security & Best Practices
🎛️ Usage
Automatic (Recommended)
komodo-defi-frameworkwith"status: pending docs"Manual Trigger
falsefor real issues,truefor testing"123,456"AI Summaries (Optional)
OPENAI_API_KEYrepository secret🔄 Future Enhancements
This foundation enables future improvements:
This workflow significantly improves our documentation process automation while maintaining full control and transparency. It's production-ready and designed to handle the scale and complexity of the Komodo Platform development workflow.