import { type Static } from "@sinclair/typebox"; import { type MarketRegimeArtifact } from "../artifacts.js"; import type { Candle, SmMarket } from "../types.js"; declare const opportunityConfigSchema: import("@sinclair/typebox").TObject<{ minCompositeScore: import("@sinclair/typebox").TOptional; pillarWeights: import("@sinclair/typebox").TOptional; marketStructure: import("@sinclair/typebox").TOptional; technicals: import("@sinclair/typebox").TOptional; funding: import("@sinclair/typebox").TOptional; }>>; rsiPeriod: import("@sinclair/typebox").TOptional; emaFast: import("@sinclair/typebox").TOptional; emaSlow: import("@sinclair/typebox").TOptional; maxCandidates: import("@sinclair/typebox").TOptional; minDayVolume: import("@sinclair/typebox").TOptional; hardDisqualifiers: import("@sinclair/typebox").TOptional; extremeRsiBounds: import("@sinclair/typebox").TOptional>; volumeDyingMultiplier: import("@sinclair/typebox").TOptional; heavyFundingAnnualizedPct: import("@sinclair/typebox").TOptional; btcHeadwindThreshold: import("@sinclair/typebox").TOptional; }>>; }>; export type OpportunityConfig = Static; interface ResolvedHardDisqualifiers { counterTrendStrengthThreshold: number; extremeRsiBounds: [number, number]; volumeDyingMultiplier: number; heavyFundingAnnualizedPct: number; btcHeadwindThreshold: number; } export interface OpportunityState { previousScores: Record; scanCount: number; } /** Annualizes a Hyperliquid hourly funding rate to a percentage. */ export declare function annualizeFunding(rate: number): number; /** Determines if funding direction is favorable for the given position side. */ export declare function isFundingFavorable(direction: "LONG" | "SHORT", fundingRate: number): boolean; /** * Scores the funding pillar (0-100). * Ported from Fox's opportunity-scan-v6.py `score_funding()`. */ export declare function scoreFunding(fundingRate: number, direction: "LONG" | "SHORT"): number; /** * Scores the smart-money pillar (0-100). * * Factors: trader count concentration + contribution conviction. */ export declare function scoreSmartMoney(sm: SmMarket | undefined): number; /** * Scores the market structure pillar (0-100). * * Uses swing pattern detection on highs/lows for the given direction. */ export declare function scoreMarketStructure(candles: Candle[], direction: "LONG" | "SHORT"): number; /** * Scores the technicals pillar (0-100). * * Uses RSI + EMA crossover for trend alignment with direction. */ export declare function scoreTechnicals(candles: Candle[], direction: "LONG" | "SHORT", rsiPeriod: number, emaFast: number, emaSlow: number): number; export interface DisqualifyResult { disqualified: boolean; reason?: string; } /** * Checks hard disqualifiers. Returns the first matching reason or null. */ export declare function checkDisqualifiers(candles: Candle[], direction: "LONG" | "SHORT", fundingRate: number, regimeArtifact: MarketRegimeArtifact | undefined, cfg: ResolvedHardDisqualifiers, emaFast: number, emaSlow: number, rsiPeriod: number): DisqualifyResult; /** * Creates the opportunity scanner. * * Deep technical scan across prescreened candidates with 4-pillar scoring: * Smart Money (25%), Market Structure (25%), Technicals (25%), Funding (25%). * * Hard disqualifiers are applied before pillar scoring to eliminate noise. * Depends on the prescreener artifact (required) and market-regime artifact * (optional) for macro context. */ export declare function opportunityScanner(): import("../index.js").Scanner<{ maxCandidates?: number | undefined; minDayVolume?: number | undefined; emaFast?: number | undefined; emaSlow?: number | undefined; minCompositeScore?: number | undefined; pillarWeights?: { funding?: number | undefined; smartMoney?: number | undefined; marketStructure?: number | undefined; technicals?: number | undefined; } | undefined; rsiPeriod?: number | undefined; hardDisqualifiers?: { counterTrendStrengthThreshold?: number | undefined; extremeRsiBounds?: [number, number] | undefined; volumeDyingMultiplier?: number | undefined; heavyFundingAnnualizedPct?: number | undefined; btcHeadwindThreshold?: number | undefined; } | undefined; }, OpportunityState>; export {}; //# sourceMappingURL=opportunity.d.ts.map