Update gpt, form
This commit is contained in:
parent
f9ac92ddf9
commit
507f228888
|
|
@ -29,3 +29,4 @@ storage/system_logs
|
|||
storage/ios
|
||||
storage/i
|
||||
storage/license
|
||||
storage/report_sn
|
||||
|
|
|
|||
|
|
@ -537,14 +537,6 @@ export default class LineConnection {
|
|||
}, 5000)
|
||||
return
|
||||
} else if (timeoutTimer) clearTimeout(timeoutTimer)
|
||||
this.outputScenario += `\n---end-scenarios---${now}---${userName}---\n`
|
||||
this.outputBuffer = ''
|
||||
this.config.runningScenario = ''
|
||||
this.socketIO.emit('running_scenario', {
|
||||
stationId: this.config.stationId,
|
||||
lineId: this.config.id,
|
||||
title: '',
|
||||
})
|
||||
|
||||
const logScenarios = this.outputScenario
|
||||
const data = textfsmResults(logScenarios, '')
|
||||
|
|
@ -604,6 +596,9 @@ export default class LineConnection {
|
|||
scenario.title.includes('DPELP') &&
|
||||
script.title.includes('DPELP')
|
||||
) {
|
||||
this.outputScenario += `\n---end-scenarios---${now}---${userName}---\n`
|
||||
this.outputBuffer = ''
|
||||
this.config.runningScenario = ''
|
||||
this.listScenarios.push(scenario.id)
|
||||
// this.outputScenario = ''
|
||||
this.runScript(scenario, userName)
|
||||
|
|
@ -651,6 +646,14 @@ export default class LineConnection {
|
|||
// this.updateNote(result.sn, result)
|
||||
// }
|
||||
}
|
||||
this.outputScenario += `\n---end-scenarios---${now}---${userName}---\n`
|
||||
this.outputBuffer = ''
|
||||
this.config.runningScenario = ''
|
||||
this.socketIO.emit('running_scenario', {
|
||||
stationId: this.config.stationId,
|
||||
lineId: this.config.id,
|
||||
title: '',
|
||||
})
|
||||
this.config.data = data
|
||||
this.socketIO.emit('data_textfsm', {
|
||||
stationId: this.config.stationId,
|
||||
|
|
@ -910,7 +913,6 @@ export default class LineConnection {
|
|||
|
||||
const payload = {
|
||||
model: 'gpt-5-mini',
|
||||
max_tokens: 1000,
|
||||
messages: [
|
||||
{
|
||||
role: 'user',
|
||||
|
|
@ -935,6 +937,7 @@ export default class LineConnection {
|
|||
},
|
||||
}
|
||||
)
|
||||
console.log('AI detect log response:', remoteResp.data)
|
||||
return remoteResp.data?.Status === 'OK' ? remoteResp.data?.data : ''
|
||||
} catch (error: any) {
|
||||
console.log('[ERROR] Detect log from AI', error)
|
||||
|
|
@ -2277,7 +2280,10 @@ Ports Missing/Down: ${missing.length}\n\n`
|
|||
<tr><td style="padding-bottom:10px;">
|
||||
<table cellpadding="0" cellspacing="0" border="0" width="100%" style="background:#fff;border:1px solid #e5e7eb;border-radius:10px;border-collapse:separate;">
|
||||
<tr><td style="padding:16px 20px;">
|
||||
<div style="font-size:11px;font-weight:700;text-transform:uppercase;letter-spacing:.8px;color:#9ca3af;padding-bottom:7px;border-bottom:1px solid #f0f1f3;margin-bottom:10px;">Receiving & Inspection Notes</div>
|
||||
<div style="display:flex;justify-content:space-between; align-items:center;border-bottom:1px solid #f0f1f3;padding-bottom:10px;">
|
||||
<div style="font-size:11px;font-weight:700;text-transform:uppercase;letter-spacing:.8px;color:#9ca3af;">Receiving & Inspection Notes</div>
|
||||
<div style="color:#222222;font-size:11px;font-weight:500;opacity:.65;">${dataIncomingBySN?.packagePo?.receivedBy?.fullName || 'Unknown'} · ${dataIncomingBySN?.packagePo?.receivedDate ? momentTZ(dataIncomingBySN?.packagePo?.receivedDate).tz(timeZone).format('DD MMM, HH:mm') : ''}</div>
|
||||
</div>
|
||||
<div style="padding:10px 14px;background:#fffbeb;border-left:3px solid #f59e0b;border-radius:0 6px 6px 0;font-size:12px;color:#92400e;margin-bottom:8px;">
|
||||
<div style="font-weight:700;margin-bottom:4px;font-size:11px;">⚠ Warning from Warehouse</div>
|
||||
<p style="margin:0;">${dataIncomingBySN?.packagePo?.notes || ''}</p>
|
||||
|
|
|
|||
Loading…
Reference in New Issue