fix(ml): add CCI to hlc_indicators list

CCI (Commodity Channel Index) requires high, low, and close prices
This commit is contained in:
Marko Djordjevic 2026-02-15 21:08:20 +01:00
parent 57240d4eea
commit 63486bc7b5
7 changed files with 37 additions and 2 deletions

0
candle_annotator@1.0.0 Normal file
View file

View file

@ -8,7 +8,8 @@
"build": "next build", "build": "next build",
"start": "next start", "start": "next start",
"lint": "next lint", "lint": "next lint",
"import-annotations": "tsx scripts/import_talib_annotations.ts" "import-annotations": "tsx scripts/import_talib_annotations.ts",
"list-charts": "tsx scripts/list_charts.ts"
}, },
"keywords": [], "keywords": [],
"author": "", "author": "",

34
scripts/list_charts.ts Normal file
View file

@ -0,0 +1,34 @@
#!/usr/bin/env tsx
/**
* List all charts in the database
*/
import { db } from '../src/lib/db';
import { charts } from '../src/lib/db/schema';
async function main() {
console.log('=== Charts in Database ===\n');
const allCharts = await db.select().from(charts).orderBy(charts.created_at);
if (allCharts.length === 0) {
console.log('No charts found.\n');
console.log('To create a chart:');
console.log('1. Upload a CSV file at http://localhost:3000');
console.log('2. Or use the create-chart script (coming soon)');
} else {
console.log(`Found ${allCharts.length} chart(s):\n`);
for (const chart of allCharts) {
const date = new Date(chart.created_at * 1000).toISOString();
console.log(` ID: ${chart.id}`);
console.log(` Name: ${chart.name}`);
console.log(` Created: ${date}`);
console.log('');
}
}
}
main().catch((error) => {
console.error('Error:', error.message);
process.exit(1);
});

View file

@ -136,7 +136,7 @@ def _call_talib_function(
'HT_SINE', 'HT_TRENDMODE'] 'HT_SINE', 'HT_TRENDMODE']
# High-Low-Close indicators # High-Low-Close indicators
hlc_indicators = ['ULTOSC', 'NATR'] hlc_indicators = ['ULTOSC', 'NATR', 'CCI']
# OHLC indicators # OHLC indicators
ohlc_indicators = ['CDL2CROWS', 'CDL3BLACKCROWS', 'CDL3INSIDE', 'CDL3LINESTRIKE', ohlc_indicators = ['CDL2CROWS', 'CDL3BLACKCROWS', 'CDL3INSIDE', 'CDL3LINESTRIKE',

0
tsx Normal file
View file