chore(8.0): final pre-RC1 sweep — API consistency, named errors, orphans, zero-cast codebase
This commit is contained in:
parent
970e08c466
commit
1f7e365a4e
237 changed files with 1951 additions and 49413 deletions
|
|
@ -10,10 +10,11 @@
|
|||
|
||||
import inquirer from 'inquirer'
|
||||
import chalk from 'chalk'
|
||||
import ora from 'ora'
|
||||
import ora, { type Ora } from 'ora'
|
||||
import fs from 'node:fs'
|
||||
import path from 'node:path'
|
||||
import { Brainy } from '../../brainy.js'
|
||||
import type { NeuralClusterParams } from '../../types/brainy.types.js'
|
||||
|
||||
interface CommandArguments {
|
||||
action?: string;
|
||||
|
|
@ -113,10 +114,12 @@ async function handleSimilarCommand(neural: any, argv: CommandArguments): Promis
|
|||
}
|
||||
|
||||
async function handleClustersCommand(neural: any, argv: CommandArguments): Promise<void> {
|
||||
let spinner: any = null
|
||||
let spinner: Ora | null = null
|
||||
try {
|
||||
let options: any = {
|
||||
algorithm: argv.algorithm as any,
|
||||
// --algorithm arrives as a raw CLI string; the interactive prompt below
|
||||
// and neural.clusters() constrain it to the supported algorithms.
|
||||
algorithm: argv.algorithm as NeuralClusterParams['algorithm'],
|
||||
threshold: argv.threshold,
|
||||
maxClusters: argv.limit
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue