chore: cleanup
This commit is contained in:
parent
2e0c43966c
commit
df4a973891
1 changed files with 3 additions and 4 deletions
|
|
@ -7,7 +7,6 @@ import { lazy } from "../util/lazy"
|
||||||
import { PermissionNext } from "../permission/next"
|
import { PermissionNext } from "../permission/next"
|
||||||
import type { Agent } from "../agent/agent"
|
import type { Agent } from "../agent/agent"
|
||||||
|
|
||||||
// what models does opencode provider support? Read: https://models.dev/api.json
|
|
||||||
export namespace Truncate {
|
export namespace Truncate {
|
||||||
export const MAX_LINES = 2000
|
export const MAX_LINES = 2000
|
||||||
export const MAX_BYTES = 50 * 1024
|
export const MAX_BYTES = 50 * 1024
|
||||||
|
|
@ -59,9 +58,9 @@ export namespace Truncate {
|
||||||
}
|
}
|
||||||
|
|
||||||
const out: string[] = []
|
const out: string[] = []
|
||||||
var i = 0
|
let i = 0
|
||||||
var bytes = 0
|
let bytes = 0
|
||||||
var hitBytes = false
|
let hitBytes = false
|
||||||
|
|
||||||
if (direction === "head") {
|
if (direction === "head") {
|
||||||
for (i = 0; i < lines.length && i < maxLines; i++) {
|
for (i = 0; i < lines.length && i < maxLines; i++) {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue