changed endpoint for new version of the api
This commit is contained in:
parent
9d9eab5db0
commit
391a357d16
1 changed files with 6 additions and 6 deletions
|
|
@ -2,7 +2,7 @@ import axios from "axios";
|
|||
|
||||
export async function getPrompts() {
|
||||
const promises = (await axios.get("http://localhost:5003/list/prompts")).data.map(async (value, index) => {
|
||||
const prompt = await axios.get("http://localhost:5003/templates/prompt", {
|
||||
const prompt = await axios.get("http://localhost:5003/signatures/prompt", {
|
||||
params: { name: value },
|
||||
});
|
||||
return { name: value, type: "promptNode", ...prompt.data };
|
||||
|
|
@ -12,7 +12,7 @@ export async function getPrompts() {
|
|||
|
||||
export async function getChains() {
|
||||
const promises = (await axios.get("http://localhost:5003/list/chains")).data.map(async (value, index) => {
|
||||
const chain = await axios.get("http://localhost:5003/templates/chain", {
|
||||
const chain = await axios.get("http://localhost:5003/signatures/chain", {
|
||||
params: { name: value },
|
||||
});
|
||||
return { name: value, type: "chainNode", ...chain.data };
|
||||
|
|
@ -22,7 +22,7 @@ export async function getChains() {
|
|||
|
||||
export async function getAgents() {
|
||||
const promises = (await axios.get("http://localhost:5003/list/agents")).data.map(async (value, index) => {
|
||||
const chain = await axios.get("http://localhost:5003/templates/agent", {
|
||||
const chain = await axios.get("http://localhost:5003/signatures/agent", {
|
||||
params: { name: value },
|
||||
});
|
||||
return { name: value, type: "agentNode", ...chain.data };
|
||||
|
|
@ -32,7 +32,7 @@ export async function getAgents() {
|
|||
|
||||
export async function getMemories() {
|
||||
const promises = (await axios.get("http://localhost:5003/list/memories")).data.map(async (value, index) => {
|
||||
const chain = await axios.get("http://localhost:5003/templates/memory", {
|
||||
const chain = await axios.get("http://localhost:5003/signatures/memory", {
|
||||
params: { name: value },
|
||||
});
|
||||
return { name: value, type: "memoryNode", ...chain.data };
|
||||
|
|
@ -42,7 +42,7 @@ export async function getMemories() {
|
|||
|
||||
export async function getTools() {
|
||||
const promises = (await axios.get("http://localhost:5003/list/tools")).data.map(async (value, index) => {
|
||||
const prompt = await axios.get("http://localhost:5003/templates/tool", {
|
||||
const prompt = await axios.get("http://localhost:5003/signatures/tool", {
|
||||
params: { name: value },
|
||||
});
|
||||
return { name: value, type: "toolNode", ...prompt.data };
|
||||
|
|
@ -52,7 +52,7 @@ export async function getTools() {
|
|||
|
||||
export async function getModels() {
|
||||
const promises = (await axios.get("http://localhost:5003/list/llms")).data.map(async (value, index) => {
|
||||
const prompt = await axios.get("http://localhost:5003/templates/llm", {
|
||||
const prompt = await axios.get("http://localhost:5003/signatures/llm", {
|
||||
params: { name: value },
|
||||
});
|
||||
return { name: value, type: "modelNode", ...prompt.data };
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue