Skip to content

Commit

Permalink
Merge pull request #14 from Chainlit/hugues/eng-1158-cookbook-example…
Browse files Browse the repository at this point in the history
…-evaluate-conversation

Add stepTypesToKeep to getThreads()
  • Loading branch information
willydouhard authored Apr 22, 2024
2 parents 7f8b2d0 + c264682 commit 24b5edf
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/api.ts
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ import {
Prompt,
Score,
Step,
StepType,
User,
Utils
} from './types';
Expand Down Expand Up @@ -776,6 +777,7 @@ export class API {
before?: Maybe<string>;
filters?: ThreadsFilter[];
orderBy?: ThreadsOrderBy;
stepTypesToKeep?: StepType[];
}): Promise<PaginatedResponse<CleanThreadFields>> {
const query = `
query GetThreads(
Expand All @@ -787,6 +789,7 @@ export class API {
$first: Int,
$last: Int,
$projectId: String,
$stepTypesToKeep: [StepType!],
) {
threads(
after: $after,
Expand All @@ -797,6 +800,7 @@ export class API {
first: $first,
last: $last,
projectId: $projectId,
stepTypesToKeep: $stepTypesToKeep,
) {
pageInfo {
startCursor
Expand Down

0 comments on commit 24b5edf

Please sign in to comment.