diff --git a/COURSE_STRUCTURE.md b/COURSE_STRUCTURE.md index 2a38e60..c21e41a 100644 --- a/COURSE_STRUCTURE.md +++ b/COURSE_STRUCTURE.md @@ -129,7 +129,7 @@ public/content/learn/ ```markdown --- hero: - title: "Understanding Derivatives" + title: "Derivatives" subtitle: "The Foundation of Neural Network Training" tags: - "📐 Mathematics" diff --git a/app/blog/the-most-difficult-project-in-human-history/page.tsx b/app/blog/the-most-difficult-project-in-human-history/page.tsx new file mode 100644 index 0000000..f1d1d8f --- /dev/null +++ b/app/blog/the-most-difficult-project-in-human-history/page.tsx @@ -0,0 +1,357 @@ +'use client'; + +import Link from "next/link"; +import { useLanguage } from "@/components/providers/language-provider"; +import { MarkdownRenderer } from "@/components/markdown-renderer"; +import { useEffect, useState } from "react"; + +interface HeroData { + title: string; + subtitle: string; + tags: string[]; +} + +export default function MostDifficultProject() { + const { language } = useLanguage(); + const [markdownContent, setMarkdownContent] = useState(''); + const [heroData, setHeroData] = useState(null); + const [isLoading, setIsLoading] = useState(true); + const [copySuccess, setCopySuccess] = useState(false); + + useEffect(() => { + const fetchMarkdownContent = async () => { + try { + const filename = language === 'zh' ? 'content-zh.md' : 'content.md'; + const response = await fetch(`/content/the-most-difficult-project-in-human-history/${filename}`); + const content = await response.text(); + + // Parse frontmatter + const frontmatterMatch = content.match(/^---\n([\s\S]*?)\n---\n([\s\S]*)$/); + if (frontmatterMatch) { + const frontmatterContent = frontmatterMatch[1]; + const markdownBody = frontmatterMatch[2]; + + // Parse YAML-like frontmatter (simple parsing for our use case) + const heroData: HeroData = { + title: "The Most Difficult Project in Human History", + subtitle: "", + tags: ["🎯 Mission", "🧠 Learning Journey"] + }; + + // Extract values from frontmatter + const lines = frontmatterContent.split('\n'); + let currentKey = ''; + let currentArray: string[] = []; + + for (const line of lines) { + const trimmedLine = line.trim(); + if (trimmedLine.startsWith('hero:')) continue; + + if (trimmedLine.includes(':')) { + const [key, ...valueParts] = trimmedLine.split(':'); + const value = valueParts.join(':').trim().replace(/^["']|["']$/g, ''); + + switch (key.trim()) { + case 'title': + heroData.title = value; + break; + case 'subtitle': + heroData.subtitle = value; + break; + case 'tags': + currentKey = 'tags'; + currentArray = []; + break; + } + } else if (trimmedLine.startsWith('- ')) { + if (currentKey === 'tags') { + const tagValue = trimmedLine.substring(2).replace(/^["']|["']$/g, ''); + currentArray.push(tagValue); + } + } else if (trimmedLine === '' && currentArray.length > 0) { + if (currentKey === 'tags') { + heroData.tags = currentArray; + currentArray = []; + currentKey = ''; + } + } + } + + // Handle final array + if (currentArray.length > 0 && currentKey === 'tags') { + heroData.tags = currentArray; + } + + setHeroData(heroData); + setMarkdownContent(markdownBody); + } else { + // Fallback if no frontmatter + setMarkdownContent(content); + } + } catch (error) { + console.error('Failed to fetch markdown content:', error); + setMarkdownContent('# Error loading content\n\nFailed to load the article content.'); + } finally { + setIsLoading(false); + } + }; + + fetchMarkdownContent(); + }, [language]); + + const handleCopyArticle = async () => { + try { + // Get the raw markdown content without frontmatter + const filename = language === 'zh' ? 'content-zh.md' : 'content.md'; + const response = await fetch(`/content/the-most-difficult-project-in-human-history/${filename}`); + const content = await response.text(); + + // Remove frontmatter if present + let contentWithoutFrontmatter = content.replace(/^---\n[\s\S]*?\n---\n/, ''); + + // Remove image paths (markdown image syntax: ![alt text](image-path)) + contentWithoutFrontmatter = contentWithoutFrontmatter.replace(/!\[.*?\]\(.*?\)/g, ''); + + await navigator.clipboard.writeText(contentWithoutFrontmatter); + setCopySuccess(true); + setTimeout(() => setCopySuccess(false), 2000); + } catch (error) { + console.error('Failed to copy article:', error); + } + }; + + if (isLoading) { + return ( +
+
+
+

Loading article content...

+
+
+ ); + } + + return ( + <> + {/* Hero Section */} +
+ {/* Background effects */} +
+
+
+
+ + {/* Animated background particles */} +
+
+
+
+
+
+ +
+
+
+

+ + {heroData?.title || (language === 'en' ? 'The Most Difficult Project in Human History' : '人类历史上最困难的项目')} + +

+
+ {heroData?.subtitle || (language === 'en' + ? '' + : '' + )} +
+ + {/* Tags */} + {heroData?.tags && heroData.tags.length > 0 && ( +
+ {heroData.tags.map((tag, index) => ( + + {index > 0 && } + + {tag.includes('🎯') && ( + + + + )} + {tag.includes('🧠') && ( + + + + )} + {tag.replace(/[🎯🧠]/g, '').trim()} + + + ))} +
+ )} + + {/* Glow effect for the title */} +
+ + {heroData?.title || (language === 'en' ? 'The Most Difficult Project in Human History' : '人类历史上最困难的项目')} + +
+
+
+
+
+ + {/* Main Content */} +
+
+ {/* Article Container */} +
+ {/* Content Card */} +
+ {/* Copy Button at Top */} +
+
+
+ + + {/* Tooltip */} +
+ {language === 'en' + ? 'Perfect for pasting into AI chatbots for self-studying! 🤖' + : '非常适合粘贴到AI聊天机器人进行自学!🤖' + } + {/* Tooltip arrow */} +
+
+
+
+
+ + {/* Article Body */} +
+
+ +
+
+ + {/* Article Footer */} +
+
+
+ + + + + Open Superintelligence Lab + +
+
+ Share + + {/* Copy Article Button */} +
+ + + {/* Tooltip */} +
+ {language === 'en' + ? 'Perfect for pasting into AI chatbots for self-studying! 🤖' + : '非常适合粘贴到AI聊天机器人进行自学!🤖' + } + {/* Tooltip arrow */} +
+
+
+ + + + + + + + + + + +
+
+
+
+ + {/* Navigation */} +
+ + + + + {language === 'en' ? 'Back to Home' : '返回首页'} + + +
+ Scroll to + +
+
+
+
+
+ + ); +} + diff --git a/app/blog/tiny-recursive-model/page.tsx b/app/blog/tiny-recursive-model/page.tsx new file mode 100644 index 0000000..73e242d --- /dev/null +++ b/app/blog/tiny-recursive-model/page.tsx @@ -0,0 +1,387 @@ +'use client'; + +import Link from "next/link"; +import { useLanguage } from "@/components/providers/language-provider"; +import { MarkdownRenderer } from "@/components/markdown-renderer"; +import { useEffect, useState } from "react"; + +interface HeroData { + title: string; + subtitle: string; + tags: string[]; +} + +export default function TinyRecursiveModelProject() { + const { language } = useLanguage(); + const [markdownContent, setMarkdownContent] = useState(''); + const [heroData, setHeroData] = useState(null); + const [isLoading, setIsLoading] = useState(true); + const [copySuccess, setCopySuccess] = useState(false); + + useEffect(() => { + const fetchMarkdownContent = async () => { + try { + const filename = language === 'zh' ? 'tiny-recursive-model-content-zh.md' : 'tiny-recursive-model-content.md'; + const response = await fetch(`/content/tiny-recursive-model/${filename}`); + const content = await response.text(); + + // Parse frontmatter + const frontmatterMatch = content.match(/^---\n([\s\S]*?)\n---\n([\s\S]*)$/); + if (frontmatterMatch) { + const frontmatterContent = frontmatterMatch[1]; + const markdownBody = frontmatterMatch[2]; + + // Parse YAML-like frontmatter (simple parsing for our use case) + const heroData: HeroData = { + title: "Tiny Recursive Model", + subtitle: "Exploring recursive architectures for efficient AI models", + tags: ["⏱️ Technical Deep Dive", "📄 Research Article"] + }; + + // Extract values from frontmatter + const lines = frontmatterContent.split('\n'); + let currentKey = ''; + let currentArray: string[] = []; + + for (const line of lines) { + const trimmedLine = line.trim(); + if (trimmedLine.startsWith('hero:')) continue; + + if (trimmedLine.includes(':')) { + const [key, ...valueParts] = trimmedLine.split(':'); + const value = valueParts.join(':').trim().replace(/^["']|["']$/g, ''); + + switch (key.trim()) { + case 'title': + heroData.title = value; + break; + case 'subtitle': + heroData.subtitle = value; + break; + case 'tags': + currentKey = 'tags'; + currentArray = []; + break; + } + } else if (trimmedLine.startsWith('- ')) { + if (currentKey === 'tags') { + const tagValue = trimmedLine.substring(2).replace(/^["']|["']$/g, ''); + currentArray.push(tagValue); + } + } else if (trimmedLine === '' && currentArray.length > 0) { + if (currentKey === 'tags') { + heroData.tags = currentArray; + currentArray = []; + currentKey = ''; + } + } + } + + // Handle final array + if (currentArray.length > 0 && currentKey === 'tags') { + heroData.tags = currentArray; + } + + setHeroData(heroData); + setMarkdownContent(markdownBody); + } else { + // Fallback if no frontmatter + setMarkdownContent(content); + } + } catch (error) { + console.error('Failed to fetch markdown content:', error); + setMarkdownContent('# Error loading content\n\nFailed to load the article content.'); + } finally { + setIsLoading(false); + } + }; + + fetchMarkdownContent(); + }, [language]); + + const handleCopyArticle = async () => { + try { + // Get the raw markdown content without frontmatter + const filename = language === 'zh' ? 'tiny-recursive-model-content-zh.md' : 'tiny-recursive-model-content.md'; + const response = await fetch(`/content/tiny-recursive-model/${filename}`); + const content = await response.text(); + + // Remove frontmatter if present + let contentWithoutFrontmatter = content.replace(/^---\n[\s\S]*?\n---\n/, ''); + + // Remove image paths (markdown image syntax: ![alt text](image-path)) + contentWithoutFrontmatter = contentWithoutFrontmatter.replace(/!\[.*?\]\(.*?\)/g, ''); + + await navigator.clipboard.writeText(contentWithoutFrontmatter); + setCopySuccess(true); + setTimeout(() => setCopySuccess(false), 2000); + } catch (error) { + console.error('Failed to copy article:', error); + } + }; + + if (isLoading) { + return ( +
+
+
+

Loading article content...

+
+
+ ); + } + + return ( + <> + {/* Hero Section */} +
+ {/* Background effects */} +
+
+
+
+ + {/* Animated background particles */} +
+
+
+
+
+
+ +
+
+
+

+ + {heroData?.title || 'Tiny Recursive Model'} + +

+
+ {heroData?.subtitle || 'Exploring recursive architectures for efficient AI models'} +
+ + {/* Tags */} + {heroData?.tags && heroData.tags.length > 0 && ( +
+ {heroData.tags.map((tag, index) => ( + + {index > 0 && } + + {tag.includes('⏱️') && ( + + + + )} + {tag.includes('📄') && ( + + + + )} + {tag.replace(/[⏱️📄]/g, '').trim()} + + + ))} +
+ )} + + {/* Links to Paper and GitHub */} + + + {/* Glow effect for the title */} +
+ + {heroData?.title || 'Tiny Recursive Model'} + +
+
+
+
+
+ + {/* Main Content */} +
+
+ {/* Article Container */} +
+ {/* Content Card */} +
+ {/* Copy Button at Top */} +
+
+
+ + + {/* Tooltip */} +
+ {language === 'en' + ? 'Perfect for pasting into AI chatbots for self-studying! 🤖' + : '非常适合粘贴到AI聊天机器人进行自学!🤖' + } + {/* Tooltip arrow */} +
+
+
+
+
+ + {/* Article Body */} +
+
+ +
+
+ + {/* Article Footer */} +
+
+
+ + + + + Open Superintelligence Lab + +
+
+ Share + + {/* Copy Article Button */} +
+ + + {/* Tooltip */} +
+ {language === 'en' + ? 'Perfect for pasting into AI chatbots for self-studying! 🤖' + : '非常适合粘贴到AI聊天机器人进行自学!🤖' + } + {/* Tooltip arrow */} +
+
+
+ + + + + + + + + + + +
+
+
+
+ + {/* Navigation */} +
+ + + + + {language === 'en' ? 'Back to Home' : '返回首页'} + + +
+ Scroll to + +
+
+
+
+
+ + ); +} + + diff --git a/app/humans-and-ai/lord-of-the-flies/page.tsx b/app/humans-and-ai/lord-of-the-flies/page.tsx new file mode 100644 index 0000000..620918b --- /dev/null +++ b/app/humans-and-ai/lord-of-the-flies/page.tsx @@ -0,0 +1,354 @@ +'use client'; + +import Link from "next/link"; +import { useLanguage } from "@/components/providers/language-provider"; +import { MarkdownRenderer } from "@/components/markdown-renderer"; +import { useEffect, useState } from "react"; + +interface HeroData { + title: string; + subtitle: string; + tags: string[]; +} + +export default function LordOfTheFlies() { + const { language } = useLanguage(); + const [markdownContent, setMarkdownContent] = useState(''); + const [heroData, setHeroData] = useState(null); + const [isLoading, setIsLoading] = useState(true); + const [copySuccess, setCopySuccess] = useState(false); + + useEffect(() => { + const fetchMarkdownContent = async () => { + try { + const filename = language === 'zh' ? 'content-zh.md' : 'content.md'; + const response = await fetch(`/content/humans-and-ai/lord-of-the-flies/${filename}`); + const content = await response.text(); + + // Parse frontmatter + const frontmatterMatch = content.match(/^---\n([\s\S]*?)\n---\n([\s\S]*)$/); + if (frontmatterMatch) { + const frontmatterContent = frontmatterMatch[1]; + const markdownBody = frontmatterMatch[2]; + + // Parse YAML-like frontmatter (simple parsing for our use case) + const heroData: HeroData = { + title: "Lord of the Flies", + subtitle: "A novel by William Golding", + tags: ["📚 Classic Literature", "🎭 Allegory"] + }; + + // Extract values from frontmatter + const lines = frontmatterContent.split('\n'); + let currentKey = ''; + let currentArray: string[] = []; + + for (const line of lines) { + const trimmedLine = line.trim(); + if (trimmedLine.startsWith('hero:')) continue; + + if (trimmedLine.includes(':')) { + const [key, ...valueParts] = trimmedLine.split(':'); + const value = valueParts.join(':').trim().replace(/^["']|["']$/g, ''); + + switch (key.trim()) { + case 'title': + heroData.title = value; + break; + case 'subtitle': + heroData.subtitle = value; + break; + case 'tags': + currentKey = 'tags'; + currentArray = []; + break; + } + } else if (trimmedLine.startsWith('- ')) { + if (currentKey === 'tags') { + const tagValue = trimmedLine.substring(2).replace(/^["']|["']$/g, ''); + currentArray.push(tagValue); + } + } else if (trimmedLine === '' && currentArray.length > 0) { + if (currentKey === 'tags') { + heroData.tags = currentArray; + currentArray = []; + currentKey = ''; + } + } + } + + // Handle final array + if (currentArray.length > 0 && currentKey === 'tags') { + heroData.tags = currentArray; + } + + setHeroData(heroData); + setMarkdownContent(markdownBody); + } else { + // Fallback if no frontmatter + setMarkdownContent(content); + } + } catch (error) { + console.error('Failed to fetch markdown content:', error); + setMarkdownContent('# Error loading content\n\nFailed to load the article content.'); + } finally { + setIsLoading(false); + } + }; + + fetchMarkdownContent(); + }, [language]); + + const handleCopyArticle = async () => { + try { + // Get the raw markdown content without frontmatter + const filename = language === 'zh' ? 'content-zh.md' : 'content.md'; + const response = await fetch(`/content/humans-and-ai/lord-of-the-flies/${filename}`); + const content = await response.text(); + + // Remove frontmatter if present + let contentWithoutFrontmatter = content.replace(/^---\n[\s\S]*?\n---\n/, ''); + + // Remove image paths (markdown image syntax: ![alt text](image-path)) + contentWithoutFrontmatter = contentWithoutFrontmatter.replace(/!\[.*?\]\(.*?\)/g, ''); + + await navigator.clipboard.writeText(contentWithoutFrontmatter); + setCopySuccess(true); + setTimeout(() => setCopySuccess(false), 2000); + } catch (error) { + console.error('Failed to copy article:', error); + } + }; + + if (isLoading) { + return ( +
+
+
+

Loading article content...

+
+
+ ); + } + + return ( + <> + {/* Hero Section */} +
+ {/* Background effects */} +
+
+
+
+ + {/* Animated background particles */} +
+
+
+
+
+
+ +
+
+
+

+ + {heroData?.title || 'Lord of the Flies'} + +

+
+ {heroData?.subtitle || 'A novel by William Golding'} +
+ + {/* Tags */} + {heroData?.tags && heroData.tags.length > 0 && ( +
+ {heroData.tags.map((tag, index) => ( + + {index > 0 && } + + {tag.includes('📚') && ( + + + + )} + {tag.includes('🎭') && ( + + + + )} + {tag.replace(/[📚🎭]/g, '').trim()} + + + ))} +
+ )} + + {/* Glow effect for the title */} +
+ + {heroData?.title || 'Lord of the Flies'} + +
+
+
+
+
+ + {/* Main Content */} +
+
+ {/* Article Container */} +
+ {/* Content Card */} +
+ {/* Copy Button at Top */} +
+
+
+ + + {/* Tooltip */} +
+ {language === 'en' + ? 'Copy essay for study and reflection 📖' + : '复制文章以供学习和反思 📖' + } + {/* Tooltip arrow */} +
+
+
+
+
+ + {/* Article Body */} +
+
+ +
+
+ + {/* Article Footer */} +
+
+
+ + + + + Humans & AI + +
+
+ Share + + {/* Copy Article Button */} +
+ + + {/* Tooltip */} +
+ {language === 'en' + ? 'Copy essay for study and reflection 📖' + : '复制文章以供学习和反思 📖' + } + {/* Tooltip arrow */} +
+
+
+ + + + + + + + + + + +
+
+
+
+ + {/* Navigation */} +
+ + + + + {language === 'en' ? 'Back to Humans & AI' : '返回人类与AI'} + + +
+ Scroll to + +
+
+
+
+
+ + ); +} + diff --git a/app/humans-and-ai/page.tsx b/app/humans-and-ai/page.tsx new file mode 100644 index 0000000..b1cd6f3 --- /dev/null +++ b/app/humans-and-ai/page.tsx @@ -0,0 +1,104 @@ +'use client'; + +import Link from "next/link"; +import { useLanguage } from "@/components/providers/language-provider"; + +export default function HumansAndAI() { + const { language } = useLanguage(); + + return ( + <> + {/* Hero Section */} +
+ {/* Background effects */} +
+
+
+
+ + {/* Animated background particles */} +
+
+
+
+
+
+ +
+
+ {/* Title */} +
+

+ + {language === 'en' ? 'Humans & AI' : '人类与AI'} + +

+ + {/* Glow effect */} +
+ + {language === 'en' ? 'Humans & AI' : '人类与AI'} + +
+
+ + {/* Subtitle */} +

+ {language === 'en' + ? 'Reading and writing essays on great books to deeply understand human nature and how we can guide human use of AI toward benefiting humanity.' + : '阅读和撰写书籍评论,深入理解人性,以及如何引导人工智能的使用造福人类。'} +

+
+
+
+ + {/* Books Grid Section */} +
+
+
+ +
+ {/* Lord of the Flies */} + +
+ Classic Literature +
+
+ New +
+ +
+

+ Lord of the Flies +

+

+ William Golding's masterpiece on human nature, civilization vs. savagery, and lessons for AI governance +

+
+ William Golding (1954) + + Read Essay → + +
+
+ + +
+
+
📖
+

+ {language === 'en' ? 'More books coming soon...' : '更多书籍即将推出...'} +

+
+
+
+
+
+
+ + ); +} + diff --git a/app/learn/page.tsx b/app/learn/page.tsx index 4d2118a..16b3614 100644 --- a/app/learn/page.tsx +++ b/app/learn/page.tsx @@ -27,8 +27,8 @@ export default function LearnPage() {

{language === 'en' - ? 'Under active development, some parts are AI generated and not reviewed yet. In the end everything will be carefully reviewed and rewritten by humans to the highest quality.' - : '正在积极开发中,部分内容由AI生成尚未审核。最终所有内容都将由人工仔细审核和重写,确保最高质量'} + ? 'Under active development' + : '正在积极开发中'}

diff --git a/app/learn/transformer-feedforward/the-deepseek-mlp/page.tsx b/app/learn/transformer-feedforward/the-deepseek-mlp/page.tsx deleted file mode 100644 index 7a3ccee..0000000 --- a/app/learn/transformer-feedforward/the-deepseek-mlp/page.tsx +++ /dev/null @@ -1,12 +0,0 @@ -import { LessonPage } from "@/components/lesson-page"; - -export default function TheDeepseekMlpPage() { - return ( - - ); -} - diff --git a/app/page.tsx b/app/page.tsx index aa5b4d3..f0d2e0d 100644 --- a/app/page.tsx +++ b/app/page.tsx @@ -100,12 +100,12 @@ export default function Home() { {/* Subtitle */} -
-

+
+

The Most Difficult Project In Human History

{/* Glow effect for subtitle */} -
+
The Most Difficult Project In Human History @@ -183,7 +183,7 @@ export default function Home() {
{/* Road to AI Researcher Project */} - @@ -208,7 +208,7 @@ export default function Home() {
- + */} {/* DeepSeek Sparse Attention Project */} + {/* Tiny Recursive Model Project */} + +
+ Research +
+
+ Latest +
+ +
+

+ Tiny Recursive Model +

+

+ How a 7M parameter model beats 100x bigger models at Sudoku, Mazes, and ARC-AGI using recursive reasoning with a 2-layer transformer +

+
+ AI Research + + Learn More → + +
+
+ + {/* Pretrain LLM with NVFP4 Project */} + {/* The Most Difficult Project in Human History */} + {/* +
+ Mission +
+
+ New +
+ +
+

+ The Most Difficult Project in Human History +

+

+ Learn to implement all latest AI tech (Mamba, Gated DeltaNet, RWKV) and become an expert at fast experimentation and research +

+
+ Open Superintelligence Lab + + Start Journey → + +
+
+ */} + {/* MobileLLM-R1 Project - HIDDEN */} {/*
Open Superintelligence Lab
-
开放超级智能实验室
+ {/*
开放超级智能实验室
*/}
diff --git a/components/navigation.tsx b/components/navigation.tsx index cdeff97..5578623 100644 --- a/components/navigation.tsx +++ b/components/navigation.tsx @@ -30,12 +30,24 @@ export function Navigation({ }: NavigationProps) {
+ + {language === 'en' ? 'Home' : '首页'} + {language === 'en' ? 'Learn' : '学习'} + + {language === 'en' ? 'Humans & AI' : '人类与AI'} + {language === 'en' ? 'YouTube' : 'YouTube'} - - {language === 'en' ? 'Research' : '研究'} -