@miphamai/cli 0.7.1 β†’ 0.7.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@miphamai/cli",
3
- "version": "0.7.1",
3
+ "version": "0.7.3",
4
4
  "description": "Mipham Code β€” Multi-model open-core intelligent coding terminal by MiphamAI",
5
5
  "keywords": [
6
6
  "ai",
@@ -170,8 +170,9 @@ export class PermissionSystem {
170
170
  : 'ask'
171
171
 
172
172
  case 'auto':
173
- // Respect tool-level permissions; safety checks handled by hook layer
174
- return 'mode-baseline'
173
+ // Safety checks handled by hook layer (PreToolUse hooks).
174
+ // Bypass the static permission system so hooks are the sole gate.
175
+ return 'bypass'
175
176
 
176
177
  case 'dontAsk':
177
178
  // Only allowlisted tools free (already handled above); everything else requires approval
package/src/ui/app.tsx CHANGED
@@ -220,12 +220,36 @@ export function App({
220
220
 
221
221
  try {
222
222
  for await (const chunk of engine.process(input, controller.signal)) {
223
+ // Show thinking indicator when model is reasoning (DeepSeek V4 thinking mode)
224
+ if (chunk.reasoning_content && turnContent === '') {
225
+ setMessages((prev) => {
226
+ const updated = [...prev]
227
+ const last = updated[updated.length - 1]
228
+ if (last?.role === 'assistant' && last.content === '') {
229
+ last.content = 'πŸ’­ 思考中…'
230
+ } else if (!last || last.role !== 'assistant' || last.content !== 'πŸ’­ 思考中…') {
231
+ updated.push({ role: 'assistant', content: 'πŸ’­ 思考中…' })
232
+ }
233
+ return updated
234
+ })
235
+ }
236
+
223
237
  if (chunk.type === 'text' && chunk.content) {
224
238
  // New turn: reset per-turn accumulator and push a fresh assistant message
225
239
  if (isNewTurn) {
226
240
  turnContent = chunk.content
227
241
  isNewTurn = false
228
- setMessages((prev) => [...prev, { role: 'assistant', content: turnContent }])
242
+ setMessages((prev) => {
243
+ const updated = [...prev]
244
+ const last = updated[updated.length - 1]
245
+ // Replace "thinking" placeholder with real content
246
+ if (last?.role === 'assistant' && last.content === 'πŸ’­ 思考中…') {
247
+ last.content = turnContent
248
+ } else {
249
+ updated.push({ role: 'assistant', content: turnContent })
250
+ }
251
+ return updated
252
+ })
229
253
  } else {
230
254
  turnContent += chunk.content
231
255
  setMessages((prev) => {