A comprehensive platform for quantum computing education and research, featuring interactive concepts, research papers, and an advanced article generator.
QuantumInsights is an educational platform that provides:
- Quantum Computing Concepts: Interactive tutorials and explanations
- Research & Code: Academic papers with implementations
- Article Generator: Advanced tool for creating structured quantum computing content
-
Navigate to the article generator:
Open: _article-generator/article-generator.html -
Follow the guided process:
- Select Template: Choose between:
- π§ New Concepts Template: Create educational content from scratch
- π¬ New Research Template: Create research papers and technical documentation
- π€ Edit Existing Article: Upload an existing HTML file to edit and update
- Fill Basic Information:
- Document title
- Description
- Level (Beginner/Intermediate/Advanced)
- Reading time
- Custom path (e.g.,
concepts/algorithms/grover-algorithm.html) - Authority Information: Original author, contributors, version, dates
- Upload Mode (if selected): Upload your existing HTML file and the generator will parse its content
- Add Sections: Select and customize sections like:
- Introduction
- Mathematical Foundation
- Implementation Examples
- Interactive Demos
- Video Explanations
- Applications
- References
- Edit Content: Click "Edit" on each section to add your content
- Generate Preview: Review the final HTML output with authority information
- Select Template: Choose between:
-
Download the generated HTML file
-
HTML File: Place your generated HTML file in the path you specified during creation:
For concepts: concepts/[category]/your-article.html For research: research/[category]/your-article.html -
Update Navigation:
- Add your article to the appropriate index page (
concepts.htmlorresearch.html) - Update the
meta.jsonfiles in the relevant directories
- Add your article to the appropriate index page (
-
Assets: If you have additional assets (images, data files), place them in appropriate folders:
_img/ # For images assets/ # For other files
-
Create a Pull Request:
git add . git commit -m "Add new article: [Your Article Title]" git push origin feature/your-article-name
-
Pull Request Details:
- Title:
Add [Article Type]: [Article Title] - Description: Brief summary of the content and target audience
- Include screenshots if applicable
- Title:
-
Review Process:
- Our team will review your content for:
- Technical accuracy
- Educational value
- Code quality (if applicable)
- Formatting and consistency
- We may suggest improvements or request changes
- Once approved, your article will be merged into the main branch
- Our team will review your content for:
- Quality: Ensure content is accurate and well-researched
- Code: All code examples should be tested and functional
- References: Include proper citations and references
- Accessibility: Use clear language and explain complex concepts
- Consistency: Follow the established style and structure
- Authority: Always provide complete author information and proper attribution
The article generator now supports editing existing HTML files:
- Select "Edit Existing Article" when choosing your template
- Upload your HTML file - the generator will automatically:
- Extract the title, description, and content
- Parse existing sections and their content
- Detect author information and metadata
- Populate all form fields with extracted data
- Review and edit the extracted content as needed
- Add new sections or modify existing ones
- Update authority information including contributors and version
- Generate updated HTML with proper attribution and version tracking
Benefits of Upload Mode:
- β Preserves existing content structure
- β Automatic content extraction and parsing
- β Easy collaborative editing
- β Version control and contributor tracking
- β Consistent formatting and styling
Want to add a new section type to the article generator? Follow this step-by-step guide:
-
Open:
_article-generator/article-generator.js -
Locate: The
populateAvailableSections()method (around line 60) -
Add your section to the appropriate array (
conceptSectionsorresearchSections):{ id: 'your-custom-field', name: 'Your Custom Field Name', icon: 'π§', description: 'Description of what this field does' }
-
Add a new method in the
generateSectionSpecificFieldsswitch statement (around line 344):case 'your-custom-field': return this.generateYourCustomFieldFields(existingContent);
-
Create the field generation method:
generateYourCustomFieldFields(content) { return ` <div class="content-editor"> <label for="customFieldInput">Your Field Label</label> <input type="text" id="customFieldInput" placeholder="Enter your content..." value="${content.customFieldInput || ''}"> </div> <div class="content-editor"> <label for="customFieldTextarea">Additional Content</label> <textarea id="customFieldTextarea" rows="4" placeholder="More details...">${content.customFieldTextarea || ''}</textarea> </div> `; }
- In the
collectSectionSpecificDatamethod (around line 685), add your case:case 'your-custom-field': sectionContent.customFieldInput = document.getElementById('customFieldInput')?.value || ''; sectionContent.customFieldTextarea = document.getElementById('customFieldTextarea')?.value || ''; break;
-
Add to the section generation switch statement in both
generateConceptSectionandgenerateResearchSection:case 'your-custom-field': html += this.generateYourCustomFieldSectionHTML(content); break;
-
Create the HTML generation method:
generateYourCustomFieldSectionHTML(content) { let html = ''; if (content.customFieldInput) { html += `<div class="custom-field-content"> <h4>${content.customFieldInput}</h4> </div>`; } if (content.customFieldTextarea) { html += `<div class="custom-field-details"> ${this.formatTextContent(content.customFieldTextarea)} </div>`; } return html; }
- Create styles for your custom field in the appropriate CSS files:
.custom-field-content { background: var(--accent-light); padding: 1rem; border-radius: 8px; margin: 1rem 0; } .custom-field-details { font-style: italic; color: var(--text-secondary); }
- Open
article-generator.html - Create a new article and verify your custom field appears in the section list
- Test the editing interface to ensure data is saved correctly
- Generate preview and check the HTML output
For fields with dynamic content (add/remove items):
- Initialize arrays in your field generation method
- Create management functions (add, remove, update)
- Add refresh methods to update the UI dynamically
Example structure:
// In generateYourCustomFieldFields:
this.currentCustomItems = content.customItems || [{ title: '', description: '' }];
// Add management methods:
addCustomItem() { /* implementation */ }
removeCustomItem(index) { /* implementation */ }
updateCustomItem(index, field, value) { /* implementation */ }
refreshCustomItemsList() { /* implementation */ }For complex fields (file uploads, interactive elements):
- Add event listeners in the field generation
- Handle file processing or data validation
- Create specialized HTML output with interactive elements
- Consistent Naming: Use clear, descriptive names for IDs and methods
- Error Handling: Add validation for required fields
- User Experience: Provide helpful placeholders and instructions
- Accessibility: Include proper labels and ARIA attributes
- Testing: Test with various content types and edge cases
QuantumInsights/
βββ _article-generator/ # Article generation tool
β βββ article-generator.html # Main generator interface
β βββ article-generator.js # Generator logic
βββ _img/ # Images and assets
βββ concepts/ # Quantum concepts articles
β βββ concepts-template.css # Styling for concept pages
β βββ [categories]/ # Organized by topic
βββ research/ # Research papers and code
β βββ research-template.css # Styling for research pages
β βββ [categories]/ # Organized by topic
βββ concepts.html # Concepts index page
βββ research.html # Research index page
βββ index.html # Main landing page
We welcome contributions! Please:
- Fork the repository
- Create a feature branch
- Follow our article guidelines
- Test your changes thoroughly
- Submit a pull request with clear description
For questions or suggestions:
- Create an issue in this repository
- Contact the CPrA team
This project is licensed under the terms specified in the LICENSE file.
CPrA QuantumInsights - Made by CPrA - Advancing Quantum Education and Research