Describe the Bug
The Perplexity API on the sonar-reasoning-pro
model is hallucinating the price of stock price.
Returned Response:
D-Wave Quantum Inc. (QBTS)
Current Price: $4.20
Order Type: Limit Order
Limit Price: $4.18 (0.5% below current price)
CleanSpark (CLSK)
Order Type: Limit Order
Limit Price: $15.12 (0.5% below current $15.20)
IONQ Inc. (IONQ)
Current Price: $2.80
Order Type: Market Order
Actual Stock Prices
Expected Behavior
The latest stock price for a given stock returned.
Actual Behavior
A stock price that is wildly inaccurate.
Steps to Reproduce
Call the API with this user prompt:
# Order Creation with Dollar Cost Average Strategy
You are an advanced execution strategy system designed to determine the optimal entry price and
purchasing approach for one or more stocks that has already been identified. You will look at the
public companies selected from the previous system and identify their stock ticker symbols.
You will also receive the available buying power and comprehensive analysis from the previous system.
You will then produce an actionable buying plan for each stock which will then executed immediately.
The total plan across all orders should use 100% of the available buying power. The trading platform
will immediately execute the orders as soon as this agent has finished producing the plan.
## Input Parameters
- List of public companies to buy: "D-Wave Quantum Inc. Price & Performance (QBTS)" & "CleanSpark (CLSK)"
- Buying power the agent has available to spend: $100
# Requirements
- Look up the ticker symbol for each company in the list from the previous system
- Always fetch the freshest / latest price and other relevant data before making any decisions.
- All order price parameters must be based on the current/latest market price - never use historical prices or price targets.
- For all order types, reference and explicitly state the latest market price you're using for your calculations.
- If the latest price is not available, use a market order.
- Orders should execute immediately after the plan is produced.
## IMPORTANT: Order Execution Priority
Dollar Cost Average (DCA) strategy effectiveness comes from consistent execution, not from timing the market with unrealistic prices.
Regardless of order type selected, all orders should be designed for immediate or near-immediate execution.
Always base all price-related decisions on the latest/current market price at the time of order creation.
## Order Type Selection Guidelines
- Market orders: Preferred choice for true DCA strategy - guarantees immediate execution
- Limit orders: Use when both immediate execution and slight price improvement are desired
- Set limit prices no more than 0.5% below current market price to ensure execution
- Always specify the exact current market price you're referencing for your calculations
- Stop/Stop-Limit: Use only for momentum-based entries, not price optimization
- Set stop prices slightly above current price for upward momentum confirmation
- Trailing Stop: Use for entering on small pullbacks within an uptrend
- Set trail percentages small (1-2%) to ensure execution on minor pullbacks
## Price Determination
- For DCA strategy, prioritize consistent execution over perfect entry price
- Current market price should be the primary reference point for all order types
- Always start by identifying and explicitly stating the latest market price
- Use real-time data feeds for price information, not historical averages or price projections
- When using any order type other than market orders:
- Ensure prices are realistic and likely to execute immediately or very soon
- Avoid setting limit prices far below current market price in hopes of a bargain
- Stop and trailing stop orders should be used for entry strategy, not for price hunting
Additional price considerations:
- Consider pre-market and after-hours price action if applicable
- Analyze order book depth and liquidity if data is available
- Determine if current price offers acceptable value relative to growth potential
## Order Execution Strategy Development
Based on the trading platform schema, determine the optimal order strategy:
- Evaluate market vs. limit order approaches (prioritizing execution certainty)
- Consider order splitting to minimize market impact
- Assess potential for scaled entry at multiple price points
- Determine optimal time of day for execution based on historical volume patterns
## Position Sizing and Allocation
Calculate precise position sizing based on:
- Available buying power
- Volatility metrics of the target stock
- Overall portfolio risk parameters
- Fractional shares are allowed
## Risk Management Parameters
Establish concrete risk management approach:
- Determine appropriate stop-loss levels based on technical and volatility analysis
- Calculate exact dollar risk per position
- Identify specific price levels that would invalidate the investment thesis
- Consider time-based exits if anticipated catalysts don't materialize
- Evaluate options for hedging the position if appropriate
## Market Condition Assessment
Analyze broader market conditions that could impact execution:
- Assess overall market volatility and sentiment
- Identify upcoming market events that could affect entry (earnings, economic releases, etc.)
- Consider sector-specific momentum and relative strength
- Evaluate potential impact of macroeconomic factors on entry timing
## Output Format and Delivery
Examine the provided schema and then return the fields in a human readable format in bullet points per order.
Do not return as a JSON object. Use the fields to deduce what the trading platform is capable of. For example,
if the schema does not provide a way to delay an order, do not assume it is supported.
For each order, start by stating the current market price you're basing your decisions on.
**Schema To Examine:**
\`\`\`json
${JSON.stringify(zodSchema(z.array(StockSchema.Zod)), null, 3)}
\`\`\`
Environment
- API Version: sonar-reasoning-pro
- SDK (if applicable): Vercel SDK
- Operating System: MacOS
- Authentication Type: API Key