Home/Tools/@tpmjs/official-ratio-analysis

ratioAnalysisTool

@tpmjs/official-ratio-analysis

Calculates key financial ratios from balance sheet and income statement data

Official
finance
v0.1.1
MIT

Interactive Playground

Test @tpmjs/official-ratio-analysis (ratioAnalysisTool) with AI-powered execution

0/2000 characters

Installation & Usage

Install this tool and use it with the AI SDK

1. Install the package

npm install @tpmjs/official-ratio-analysis
pnpm add @tpmjs/official-ratio-analysis
yarn add @tpmjs/official-ratio-analysis
bun add @tpmjs/official-ratio-analysis
deno add npm:@tpmjs/official-ratio-analysis

2. Import the tool

import { ratioAnalysisTool } from '@tpmjs/official-ratio-analysis';

3. Use with AI SDK

import { generateText } from 'ai';
import { openai } from '@ai-sdk/openai';
import { ratioAnalysisTool } from '@tpmjs/official-ratio-analysis';

const result = await generateText({
  model: openai('gpt-4o'),
  tools: { ratioAnalysisTool },
  prompt: 'Your prompt here...',
});

console.log(result.text);

Signature

(financials: { cash: number; revenue: number; inventory: number; netIncome: number; grossProfit: number }) => Promise<unknown>

Tags

analysis
balance
calculates
data
finance
financial
financial-statements
income
key
official
ratio
ratios
sheet
statement
tpmjs

Parameters

Available configuration options

Auto-extracted
financials
Required
Type: object

Financial statement data including balance sheet and income statement

Schema extracted: 2/27/2026, 4:20:46 AM

README

ERROR: No README data found!

Statistics

Downloads/month

32

GitHub Stars

0

Quality Score

77%

Bundle Size

NPM Keywords

tpmjs
finance
ratios
analysis
financial-statements

Maintainers

thomasdavis(thomasalwyndavis@gmail.com)

Frameworks

vercel-ai