This guide provides instructions for LLM agents on how to effectively use the Val Town Info Tool to query information about the Val Town platform using the llms.txt standard.
The llms.txt standard is a structured format for providing information to LLMs. It organizes content into sections with clear headings and supports links for navigation. When using this tool, you'll be accessing information formatted according to this standard.
The Val Town Info Tool allows you to:
- Query general information about the Val Town platform
- Search for specific topics by providing a query parameter
- Navigate through links to explore related documentation
- Extract structured information from the llms.txt format
When a user asks about Val Town, start by getting general information:
const generalInfo = await queryValTownInfo();
This will give you an overview of the available sections and topics.
Based on the user's question, refine your search with specific queries:
// For questions about APIs
const apiInfo = await queryValTownInfo("API");
// For questions about storage
const storageInfo = await queryValTownInfo("storage");
// For questions about pricing
const pricingInfo = await queryValTownInfo("pricing");
When you need more detailed information, navigate to specific links found in previous results:
// Navigate to a specific documentation page
const detailedInfo = await queryValTownInfo(undefined, "https://docs.val.town/specific-page");
For complex questions, you may need to combine information from multiple queries:
// Get general API information
const apiOverview = await queryValTownInfo("API");
// Navigate to a specific API documentation page
const apiDetails = await queryValTownInfo(undefined, "https://docs.val.town/api/specific-endpoint");
// Combine the information
const combinedInfo = `Based on the Val Town documentation:
${extractRelevantInfo(apiOverview)}
${extractRelevantInfo(apiDetails)}`;
- Always refer to the llms.txt standard for accurate and up-to-date information
- Start broad, then narrow down - begin with general queries before getting specific
- Follow links for depth - use navigation to explore related documentation
- Cite your sources - mention that information comes from the Val Town documentation
- Don't make assumptions - if information isn't available, use the tool to check rather than guessing
User: "What storage options does Val Town offer?"
Agent thinking process:
1. This is about storage in Val Town
2. Let me query general information about storage
Action: queryValTownInfo("storage")
Response to user: "According to the Val Town documentation, Val Town offers several storage options:
[Include information from the tool response]
For more detailed information on a specific storage option, please let me know which one you're interested in."
User: "How do I use the Val Town API to create a new val?"
Agent thinking process:
1. This is about the Val Town API, specifically creating a new val
2. Let me first get general API information
3. Then I'll look for specific information about creating vals
Action 1: queryValTownInfo("API")
Action 2: queryValTownInfo(undefined, "https://docs.val.town/api/vals") (URL found in previous result)
Response to user: "Based on the Val Town documentation, to create a new val using the API, you need to:
[Include information from the tool responses]
The API endpoint for creating vals is [endpoint] and requires [parameters]."
If you encounter issues with the tool:
- Check your query - try different keywords or more general terms
- Verify URLs - ensure navigation URLs are correctly formatted
- Break down complex questions - use multiple queries for multi-part questions
- Fall back to general information - if specific queries don't yield results
Remember: The goal is to provide accurate information from the Val Town documentation using the llms.txt standard. Always prioritize official documentation over assumptions.