This document provides examples of how to use the FAQ Generator application.
Before using the FAQ Generator, ensure you have:
- GitHub CLI installed and authenticated (
gh auth login) - GitHub Copilot CLI extension installed (
npm install -g @github/copilot) - Active GitHub Copilot subscription
npm run devnpm run build
npm startThe server will start at http://localhost:3000
Example URLs to try:
- https://github.com/github/copilot-sdk
- https://nodejs.org/en/about
- Any documentation or blog post URL
Steps:
- Open http://localhost:3000
- Click the "From URL" tab (default)
- Enter a webpage URL
- Click "Generate FAQ from URL"
- Wait for the AI to analyze the content and generate FAQs
Excel file formats supported:
.xlsx(Excel 2007+).xls(Excel 97-2003)
Example scenarios:
- Upload an Excel file with existing FAQ data (columns: Question, Answer) to format and enhance it
- Upload any data spreadsheet to generate FAQs about the data
Steps:
- Click the "From Excel" tab
- Click "Choose File" and select your Excel file
- Click "Generate FAQ from Excel"
- The AI will either format existing FAQs or create new ones based on the data
Image formats supported:
.jpg/.jpeg.png.gif.bmp
Example scenarios:
- Screenshot of a product page
- Diagram or flowchart
- Photo of a document
- Chart or graph
Steps:
- Click the "From Image" tab
- Click "Choose File" and select your image
- Click "Generate FAQ from Image"
- The AI will analyze the image content and generate relevant FAQs
The generated FAQs will be formatted like this:
Q: What is GitHub Copilot SDK?
A: GitHub Copilot SDK is a toolkit that allows developers to integrate GitHub Copilot's AI capabilities into their own applications...
Q: How do I install the SDK?
A: You can install the SDK using npm: npm install @github/copilot-sdk...
Q: What programming languages are supported?
A: The SDK supports TypeScript, JavaScript, Python, Go, and .NET...
- Check that the URL is valid and accessible
- Ensure the website doesn't block automated access
- Try a different webpage
- Verify the file is a valid Excel format (.xlsx or .xls)
- Check that the file size is under 10MB
- Ensure the spreadsheet contains readable data
- Verify the image format is supported
- Check that the file size is under 10MB
- Ensure the image is not corrupted
If you see errors about the Copilot SDK:
- Ensure GitHub CLI is installed:
gh --version - Check authentication:
gh auth status - Verify Copilot CLI extension:
gh extension list - Test Copilot access:
gh copilot suggest "hello world"
You can also use the API directly:
curl -X POST http://localhost:3000/api/generate-from-url \
-H "Content-Type: application/json" \
-d '{"url": "https://example.com"}'curl -X POST http://localhost:3000/api/generate-from-excel \
-F "file=@path/to/file.xlsx"curl -X POST http://localhost:3000/api/generate-from-image \
-F "file=@path/to/image.jpg"- URLs: Use pages with clear, structured content for better FAQ generation
- Excel: Include headers in your spreadsheet for better context
- Images: Use high-quality, clear images with readable text
- Wait time: Complex content may take 10-30 seconds to process
- Model selection: The application uses GPT-4 for text and GPT-4o for images
- Try different types of content to see how the AI adapts
- Compare results from similar content in different formats
- Use the generated FAQs as a starting point and refine them
- Experiment with different websites and data sources