tamilai 0.0.1 → 0.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -1,6 +1,8 @@
1
- # tamilai
1
+ # TamilAI
2
2
 
3
- An AI assistant that responds in Tamil
3
+ Tamil-first AI powered by [PraisonAI](https://github.com/MervinPraison/PraisonAI).
4
+
5
+ A thin wrapper — all PraisonAI features work automatically with Tamil defaults.
4
6
 
5
7
  ## Installation
6
8
 
@@ -8,6 +10,28 @@ An AI assistant that responds in Tamil
8
10
  npm install tamilai
9
11
  ```
10
12
 
13
+ ## Usage
14
+
15
+ ```typescript
16
+ import { version } from 'tamilai';
17
+ ```
18
+
19
+ ## Python
20
+
21
+ ```bash
22
+ pip install tamilai
23
+ ```
24
+
25
+ ```python
26
+ from tamilai import chat, Agent
27
+
28
+ # One-liner chat in Tamil
29
+ response = chat("வணக்கம், எப்படி இருக்கிறீர்கள்?")
30
+
31
+ # Tamil agent (wraps PraisonAI)
32
+ agent = Agent(name="தமிழ் உதவியாளர்", role="Tamil Assistant")
33
+ ```
34
+
11
35
  ## License
12
36
 
13
37
  Proprietary
package/dist/index.d.ts CHANGED
@@ -1,2 +1,27 @@
1
- /** An AI assistant that responds in Tamil */
2
- export declare const version = "0.0.1";
1
+ import { Agent as PraisonAIAgent, Agents as PraisonAIAgents, SimpleAgentConfig } from 'praisonai';
2
+ /**
3
+ * TamilAI - Tamil-first AI powered by PraisonAI
4
+ *
5
+ * A thin wrapper around PraisonAI that pre-configures everything for Tamil.
6
+ * All PraisonAI features work automatically — this just sets Tamil defaults.
7
+ */
8
+ export declare const TAMIL_SYSTEM = "You are a helpful AI assistant. Always respond in Tamil (\u0BA4\u0BAE\u0BBF\u0BB4\u0BCD). Use proper Tamil grammar and script. If the user writes in English, still respond in Tamil unless explicitly asked otherwise.";
9
+ /**
10
+ * Chat one-liner helper
11
+ */
12
+ export declare function chat(message: string, options?: {
13
+ model?: string;
14
+ }): Promise<string>;
15
+ /**
16
+ * Tamil Agent - Extends PraisonAI Agent with Tamil defaults
17
+ */
18
+ export declare class Agent extends PraisonAIAgent {
19
+ constructor(config?: Partial<SimpleAgentConfig>);
20
+ }
21
+ /**
22
+ * Tamil Agents - Re-export PraisonAI Agents
23
+ */
24
+ export declare class Agents extends PraisonAIAgents {
25
+ }
26
+ export * from 'praisonai';
27
+ export declare const version = "0.0.2";
package/dist/index.js CHANGED
@@ -1,5 +1,61 @@
1
1
  "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
+ };
2
16
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.version = void 0;
4
- /** An AI assistant that responds in Tamil */
5
- exports.version = "0.0.1";
17
+ exports.version = exports.Agents = exports.Agent = exports.TAMIL_SYSTEM = void 0;
18
+ exports.chat = chat;
19
+ const praisonai_1 = require("praisonai");
20
+ /**
21
+ * TamilAI - Tamil-first AI powered by PraisonAI
22
+ *
23
+ * A thin wrapper around PraisonAI that pre-configures everything for Tamil.
24
+ * All PraisonAI features work automatically — this just sets Tamil defaults.
25
+ */
26
+ // Tamil system instruction prepended to all agents
27
+ exports.TAMIL_SYSTEM = "You are a helpful AI assistant. Always respond in Tamil (தமிழ்). Use proper Tamil grammar and script. If the user writes in English, still respond in Tamil unless explicitly asked otherwise.";
28
+ /**
29
+ * Chat one-liner helper
30
+ */
31
+ async function chat(message, options = {}) {
32
+ const agent = new Agent({
33
+ instructions: exports.TAMIL_SYSTEM,
34
+ llm: options.model
35
+ });
36
+ return agent.start(message);
37
+ }
38
+ /**
39
+ * Tamil Agent - Extends PraisonAI Agent with Tamil defaults
40
+ */
41
+ class Agent extends praisonai_1.Agent {
42
+ constructor(config = {}) {
43
+ const tamilInstructions = config.instructions
44
+ ? `${exports.TAMIL_SYSTEM}\n\nAdditional instructions: ${config.instructions}`
45
+ : exports.TAMIL_SYSTEM;
46
+ super({
47
+ ...config,
48
+ instructions: tamilInstructions
49
+ });
50
+ }
51
+ }
52
+ exports.Agent = Agent;
53
+ /**
54
+ * Tamil Agents - Re-export PraisonAI Agents
55
+ */
56
+ class Agents extends praisonai_1.Agents {
57
+ }
58
+ exports.Agents = Agents;
59
+ // Re-export everything else from praisonai
60
+ __exportStar(require("praisonai"), exports);
61
+ exports.version = "0.0.2";
package/package.json CHANGED
@@ -1,7 +1,11 @@
1
1
  {
2
2
  "name": "tamilai",
3
- "version": "0.0.1",
4
- "description": "An AI assistant that responds in Tamil",
3
+ "version": "0.0.2",
4
+ "description": "Tamil-first AI powered by PraisonAI",
5
+ "dependencies": {
6
+ "dotenv": "^16.4.7",
7
+ "praisonai": "1.7.1"
8
+ },
5
9
  "main": "dist/index.js",
6
10
  "types": "dist/index.d.ts",
7
11
  "scripts": {
@@ -15,4 +19,4 @@
15
19
  "type": "git",
16
20
  "url": "https://github.com/MervinPraison/packages"
17
21
  }
18
- }
22
+ }
package/src/index.ts CHANGED
@@ -1,2 +1,49 @@
1
- /** An AI assistant that responds in Tamil */
2
- export const version = "0.0.1";
1
+ import { Agent as PraisonAIAgent, Agents as PraisonAIAgents, SimpleAgentConfig } from 'praisonai';
2
+
3
+ /**
4
+ * TamilAI - Tamil-first AI powered by PraisonAI
5
+ *
6
+ * A thin wrapper around PraisonAI that pre-configures everything for Tamil.
7
+ * All PraisonAI features work automatically — this just sets Tamil defaults.
8
+ */
9
+
10
+ // Tamil system instruction prepended to all agents
11
+ export const TAMIL_SYSTEM = "You are a helpful AI assistant. Always respond in Tamil (தமிழ்). Use proper Tamil grammar and script. If the user writes in English, still respond in Tamil unless explicitly asked otherwise.";
12
+
13
+ /**
14
+ * Chat one-liner helper
15
+ */
16
+ export async function chat(message: string, options: { model?: string } = {}): Promise<string> {
17
+ const agent = new Agent({
18
+ instructions: TAMIL_SYSTEM,
19
+ llm: options.model
20
+ });
21
+ return agent.start(message);
22
+ }
23
+
24
+ /**
25
+ * Tamil Agent - Extends PraisonAI Agent with Tamil defaults
26
+ */
27
+ export class Agent extends PraisonAIAgent {
28
+ constructor(config: Partial<SimpleAgentConfig> = {}) {
29
+ const tamilInstructions = config.instructions
30
+ ? `${TAMIL_SYSTEM}\n\nAdditional instructions: ${config.instructions}`
31
+ : TAMIL_SYSTEM;
32
+
33
+ super({
34
+ ...config,
35
+ instructions: tamilInstructions
36
+ } as SimpleAgentConfig);
37
+ }
38
+ }
39
+
40
+ /**
41
+ * Tamil Agents - Re-export PraisonAI Agents
42
+ */
43
+ export class Agents extends PraisonAIAgents {
44
+ // Orchestrator stays as-is, but agents passed to it will be Tamil-configured
45
+ }
46
+
47
+ // Re-export everything else from praisonai
48
+ export * from 'praisonai';
49
+ export const version = "0.0.2";