Skip to content

Commit

Permalink
Merge pull request #82 from parea-ai/PAI-1402-add-history-via-p-compl…
Browse files Browse the repository at this point in the history
…etion

Pai 1402 add history via p completion
  • Loading branch information
jalexanderII authored Jul 24, 2024
2 parents 5126cd5 + 96e989c commit b2f543e
Show file tree
Hide file tree
Showing 4 changed files with 1,579 additions and 1,318 deletions.
3 changes: 3 additions & 0 deletions cookbook/tracing_with_deployed_prompt.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ const deployedArgumentGenerator = async (query: string, additionalDescription: s
date: new Date().toISOString(),
query: query,
},
llm_configuration: { history: [{ role: 'user', content: 'Some history' }] },
metadata: { source: 'parea-js-sdk' },
trace_name: 'deployedArgumentGenerator',
end_user_identifier: 'test-user',
Expand All @@ -26,6 +27,7 @@ const deployedCritic = async (argument: string): Promise<string> => {
const completion: Completion = {
deployment_id: 'p-PSOwRyIPaQRq4xQW3MbpV',
llm_inputs: { argument: argument },
llm_configuration: { history: [{ role: 'user', content: 'Some history' }] },
metadata: { source: 'parea-js-sdk' },
trace_name: 'deployedCritic',
end_user_identifier: 'test-user',
Expand All @@ -49,6 +51,7 @@ const deployedRefiner = async (
argument: argument,
criticism: criticism,
},
llm_configuration: { history: [{ role: 'user', content: 'Some history' }] },
metadata: { source: 'parea-js-sdk' },
trace_name: 'deployedRefiner',
end_user_identifier: 'test-user',
Expand Down
22 changes: 11 additions & 11 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,36 +28,36 @@
"axios-retry": "^3.9.1",
"dotenv": "^16.4.5",
"moment-timezone": "^0.5.45",
"openai": "^4.52.5",
"openai": "^4.53.0",
"semantic-release": "^21.1.2",
"ts-node": "^10.9.2",
"uuid": "^9.0.1"
},
"devDependencies": {
"@babel/core": "^7.24.0",
"@babel/preset-env": "^7.24.0",
"@babel/preset-typescript": "^7.23.3",
"@babel/core": "^7.24.9",
"@babel/preset-env": "^7.24.8",
"@babel/preset-typescript": "^7.24.7",
"@commitlint/cli": "^17.8.1",
"@commitlint/config-conventional": "^17.8.1",
"@langchain/core": "^0.1.48",
"@langchain/core": "^0.1.63",
"@langchain/openai": "^0.0.14",
"@tsconfig/recommended": "^1.0.3",
"@tsconfig/recommended": "^1.0.7",
"@types/jest": "^29.5.12",
"@types/node": "^20.11.28",
"@types/node": "^20.14.12",
"@types/uuid": "^9.0.8",
"@typescript-eslint/eslint-plugin": "^6.21.0",
"babel-jest": "^29.7.0",
"cz-conventional-changelog": "^3.3.0",
"eslint-config-prettier": "^9.1.0",
"eslint-plugin-prettier": "^5.1.3",
"eslint-plugin-prettier": "^5.2.1",
"husky": "^8.0.3",
"jest": "^29.7.0",
"langchain": "^0.1.28",
"langchain": "^0.1.37",
"lint-staged": "^14.0.1",
"prettier": "3.0.3",
"semantic-release-pnpm": "^1.0.2",
"ts-jest": "^29.1.2",
"typescript": "^5.4.2"
"ts-jest": "^29.2.3",
"typescript": "^5.5.4"
},
"scripts": {
"build": "tsc",
Expand Down
Loading

0 comments on commit b2f543e

Please sign in to comment.