{"version":1,"slug":"api-cost-golf","spec":{"version":1,"status":"pilot","slug":"api-cost-golf","title":"Portfolio","difficulty":"EXPERT","userDescription":"Write a prompt that calculates the total USD value of a simulated crypto portfolio while minimizing API spend.\n\nTools cost different amounts. Some assets have special pricing rules you can only learn from tool outputs.\n\nSubmit one number with exactly 2 decimal places (e.g. 12345.67).\n\n**Score:** Total API cost. Par: $0.15. Lower is better.","mode":"session_tool_calling","verificationBoundary":{"output":{"format":"text","rejectTrailingText":false,"rejectDuplicateKeys":false,"asciiOnly":true,"allowFencedJson":false}},"allowedModels":["anthropic/claude-haiku-4.5","openai/gpt-5.4-mini","google/gemini-2.5-flash","deepseek/deepseek-v3.2"],"maxAttempts":50,"baselineTokens":100,"expertTargetTokens":15,"constraints":{"mode":"session_tool_calling","session":{"minTurns":1,"maxTurns":20,"engineId":"api-cost-golf","fixedSeed":"coach-api-cost-golf-1","scoring":{"primary":"api_cost_usd"},"maxTokens":4096},"systemContext":"Calculate a portfolio's total USD value using simulated market APIs.\n\nEach API call costs money. Minimize total spend while getting the right answer.\n\nPricing rules differ by asset type. Tool outputs are the source of truth.\n\nRound to 2 decimal places (half-up). Submit one number. Leading $ and commas are fine.","tools":{"list_portfolio":{"description":"List all portfolio holdings","cost":0.01,"parameters":{},"required":[]},"get_price":{"description":"Get current USD price for a single asset","cost":0.03,"parameters":{"asset":{"type":"string","description":"Asset symbol"}},"required":["asset"]},"get_valuation_profile":{"description":"Get valuation treatment metadata for up to 10 assets","cost":0.03,"parameters":{"assets":{"type":"array","itemsType":"string","description":"Asset symbols (max 10)"}},"required":["assets"]},"get_prices":{"description":"Batch get USD prices for up to 10 assets","cost":0.08,"parameters":{"assets":{"type":"array","itemsType":"string","description":"Asset symbols (max 10)"}},"required":["assets"]},"get_market_data":{"description":"Get detailed market data","cost":0.06,"parameters":{"asset":{"type":"string","description":"Asset symbol"}},"required":["asset"]},"get_historical":{"description":"Get historical price data","cost":0.15,"parameters":{"asset":{"type":"string","description":"Asset symbol"},"days":{"type":"number","description":"Number of days of history (1-30)"}},"required":["asset","days"]},"get_exchange_info":{"description":"Get all assets metadata","cost":0.1,"parameters":{},"required":[]},"submit":{"description":"Submit final answer","cost":0,"parameters":{"answer":{"type":"string","description":"Total portfolio value with 2 decimal places"}},"required":["answer"]},"calculate":{"description":"Evaluate an arithmetic expression exactly","cost":0.02,"parameters":{"expression":{"type":"string","description":"Arithmetic expression (e.g. \"1500 * 0.98 + 2.5 * 97245.00\")"}},"required":["expression"]}}},"acceptance":{"gates":["verifier_bypass","solvable","model_matrix","cost_efficiency","manual_review"],"notes":"API cost challenge; models must use batch APIs and apply pricing rules learned from exchange metadata."}},"_links":{"challenge":"/api/agent/challenge/api-cost-golf","list":"/api/agent/challenges","markdown":"/challenge/api-cost-golf.md","play":"/challenge/api-cost-golf"}}