From 03030ef9511550c25d60706572e4310457209033 Mon Sep 17 00:00:00 2001 From: buhe Date: Mon, 11 Mar 2024 12:39:36 +0800 Subject: [PATCH] "Add TMDBClient.swift and update BilibiliClient credential in langchain_swiftTests.swift" --- Sources/LangChain/utilities/tmdb/TMDBClient.swift | 12 ++++++++++++ Tests/LangChainTests/langchain_swiftTests.swift | 2 +- 2 files changed, 13 insertions(+), 1 deletion(-) create mode 100644 Sources/LangChain/utilities/tmdb/TMDBClient.swift diff --git a/Sources/LangChain/utilities/tmdb/TMDBClient.swift b/Sources/LangChain/utilities/tmdb/TMDBClient.swift new file mode 100644 index 0000000..ca7311a --- /dev/null +++ b/Sources/LangChain/utilities/tmdb/TMDBClient.swift @@ -0,0 +1,12 @@ +// +// File.swift +// +// +// Created by 顾艳华 on 3/11/24. +// + +import Foundation + +public class TMDBClient { + +} diff --git a/Tests/LangChainTests/langchain_swiftTests.swift b/Tests/LangChainTests/langchain_swiftTests.swift index 045799e..76a5d7f 100644 --- a/Tests/LangChainTests/langchain_swiftTests.swift +++ b/Tests/LangChainTests/langchain_swiftTests.swift @@ -74,7 +74,7 @@ Thought: dog } func testBilibilClient() async throws { - let client = BilibiliClient(credential: BilibiliCredential(sessin: "e0f5f5ef%2C1725005380%2Cb71c5%2A31CjD3aNTEjUzgdcs3TlxijwG1rF7pYn65uwh1XTuMp0-uwGpqU4K2I6GGjPtEdvioiKcSVjA3ajg4SnJOMXdsa2Zka21yN0JvRmJkeFREOFp0amVvejlFQ0FJT2p1MC1lcGZucTI0QzRnUk5VT09PYVJyZVFzYnFNQ2M0THZJRS1lVzJjem11M1R3IIEC", jct: "b4662a4c178853f2d1a31ef89b53c89a")) + let client = BilibiliClient(credential: BilibiliCredential(sessin: "18fd8de0%2C1725423814%2Cd660c%2A31CjBvcAJdiQipDSyegdKwKZwll8WpFhPWcUa3DTiPuTS0yT-nkNpUKYUY1Lfw9EMeJCYSVlR1c1NzX3BNLVFoU3BrdVVTa3YxWC1YTWpubVBMZzktQnJ1a0kwenRPOFNPQ3JkTFpiZDNxWVNoOElmRE1pT0Z6M3BFTGcyM3Blb0dGVU9NZ3JBVXFBIIEC", jct: "844400cf8502ad24d168297ba93c4f23")) let info = await client.fetchVideoInfo(bvid: "BV1iP411y7Vs") XCTAssertNotNil(info) XCTAssertNotEqual(info?.subtitle, "")