Merge pull request #989 from vinodkiran/FEATURE/llm-cache

Feature/llm cache
This commit is contained in:
Henry Heng
2023-10-09 19:18:13 +01:00
committed by GitHub
31 changed files with 517 additions and 38 deletions
@@ -0,0 +1,36 @@
import { INodeParams, INodeCredential } from '../src/Interface'
class MomentoCacheApi implements INodeCredential {
label: string
name: string
version: number
description: string
inputs: INodeParams[]
constructor() {
this.label = 'Momento Cache API'
this.name = 'momentoCacheApi'
this.version = 1.0
this.description =
'Refer to <a target="_blank" href="https://docs.momentohq.com/cache/develop/authentication/api-keys">official guide</a> on how to get API key on Momento'
this.inputs = [
{
label: 'Cache',
name: 'momentoCache',
type: 'string'
},
{
label: 'API Key',
name: 'momentoApiKey',
type: 'password'
},
{
label: 'Endpoint',
name: 'momentoEndpoint',
type: 'string'
}
]
}
}
module.exports = { credClass: MomentoCacheApi }
@@ -0,0 +1,43 @@
import { INodeParams, INodeCredential } from '../src/Interface'
class RedisCacheApi implements INodeCredential {
label: string
name: string
version: number
description: string
inputs: INodeParams[]
constructor() {
this.label = 'Redis Cache API'
this.name = 'redisCacheApi'
this.version = 1.0
this.inputs = [
{
label: 'Redis Host',
name: 'redisCacheHost',
type: 'string',
default: '127.0.0.1'
},
{
label: 'Port',
name: 'redisCachePort',
type: 'number',
default: '6789'
},
{
label: 'User',
name: 'redisCacheUser',
type: 'string',
placeholder: '<REDIS_USERNAME>'
},
{
label: 'Password',
name: 'redisCachePwd',
type: 'password',
placeholder: '<REDIS_PASSWORD>'
}
]
}
}
module.exports = { credClass: RedisCacheApi }
@@ -0,0 +1,28 @@
import { INodeParams, INodeCredential } from '../src/Interface'
class UpstashRedisApi implements INodeCredential {
label: string
name: string
version: number
inputs: INodeParams[]
constructor() {
this.label = 'Upstash Redis API'
this.name = 'upstashRedisApi'
this.version = 1.0
this.inputs = [
{
label: 'Upstash Redis REST URL',
name: 'upstashConnectionUrl',
type: 'string'
},
{
label: 'Token',
name: 'upstashConnectionToken',
type: 'password'
}
]
}
}
module.exports = { credClass: UpstashRedisApi }