mirror of
https://github.com/langchain-ai/docs.git
synced 2026-08-27 02:41:59 -04:00
20 lines
524 B
Plaintext
20 lines
524 B
Plaintext
```kotlin Kotlin
|
|
import com.langchain.smith.tracing.RunType
|
|
import com.langchain.smith.tracing.TraceConfig
|
|
import com.langchain.smith.tracing.traceable
|
|
|
|
val myCustomLlm =
|
|
traceable(
|
|
{ prompt: String -> callCustomApi(prompt) },
|
|
TraceConfig.builder()
|
|
.runType(RunType.LLM)
|
|
.metadata(
|
|
mapOf(
|
|
"ls_provider" to "my_provider",
|
|
"ls_model_name" to "my_custom_model",
|
|
),
|
|
)
|
|
.build(),
|
|
)
|
|
```
|