| """Web-based Knowledge Update Script""" | |
| import sys | |
| from pathlib import Path | |
| sys.path.insert(0, str(Path(__file__).parent.parent)) | |
| from src.knowledge import WebUpdater, LocalKB | |
| def main(): | |
| """Update knowledge from web sources""" | |
| print("🌐 Burme-Coder-Max Web Updater") | |
| print("=" * 40) | |
| updater = WebUpdater() | |
| print("\nFetching content from web sources...") | |
| results = updater.fetch_all() | |
| print(f"\n✓ Fetched {len(results)} sources:") | |
| for name in results.keys(): | |
| print(f" - {name}") | |
| output_dir = Path(__file__).parent.parent / "data" / "knowledge" / "skills" | |
| print(f"\nUpdating markdown files to {output_dir}...") | |
| updated = updater.update_markdown_files(output_dir, force=False) | |
| print(f"✓ Updated {len(updated)} files:") | |
| for name in updated: | |
| print(f" - {name}") | |
| print("\n✅ Knowledge update complete!") | |
| if __name__ == "__main__": | |
| main() | |