Open Lazare-42 opened 7 months ago
Hey thanks for reporting!
Would you be able to tell me your Mac's RAM, the model you tried to load and the context size you tried to load it with?
I suspect this is related to too large of a model or context size and to debug you could try dropping context size down & using a small model like phi-2 or even smaller like tinyllama.
I have this same issue. I used the openhermes-2.5-mistral-7b.Q4_K_M.gguf
I have an Apple M1 Max ARM64 and 32 GB RAM Mac with Mac OS 14.3 (23D56)
At first, I got context too short but increasing it to 4096 causes the crash.
Using phi-2 I get the following error. I also tried a Context Length Setting of 16384. Setting RAG to 1 it crashes again.
Error invoking remote method 'augment-prompt-with-rag': Error: The provided information is too long to process in a single prompt. Please shorten the query or provide fewer details.
I am using Reor with my Obsidian notes folder. That maybe part of the cause.
Version 0.1.37 (0.1.37)
The app crashes when launching the chat.
Here are the first lines of log:
Translated Report (Full Report Below)
Process: Reor [26618] Path: /Applications/Reor.app/Contents/MacOS/Reor Identifier: YourAppID Version: 0.1.37 (0.1.37) Code Type: ARM-64 (Native) Parent Process: launchd [1] User ID: 502
Date/Time: 2024-01-31 14:28:22.1498 +0100 OS Version: macOS 14.1 (23B2073) Report Version: 12 Anonymous UUID: 5ECE4A44-89B2-9CD2-932E-BEB7DF949F1B
Sleep/Wake UUID: 917FC273-5A76-4602-82F9-6E62C1184C82
Time Awake Since Boot: 130000 seconds Time Since Wake: 10532 seconds
System Integrity Protection: enabled
Crashed Thread: 0 CrBrowserMain Dispatch queue: com.apple.main-thread
Exception Type: EXC_BREAKPOINT (SIGTRAP) Exception Codes: 0x0000000000000001, 0x000000010e2e7170
Termination Reason: Namespace SIGNAL, Code 5 Trace/BPT trap: 5 Terminating Process: exc handler [26618]
Thread 0 Crashed:: CrBrowserMain Dispatch queue: com.apple.main-thread 0 Electron Framework 0x10e2e7170 electron::fuses::IsLoadBrowserProcessSpecificV8SnapshotEnabled() + 13760 1 Electron Framework 0x10e2e7170 electron::fuses::IsLoadBrowserProcessSpecificV8SnapshotEnabled() + 13760 2 Electron Framework 0x10e2e7188 electron::fuses::IsLoadBrowserProcessSpecificV8SnapshotEnabled() + 13784 3 Electron Framework 0x10e2e71a4 electron::fuses::IsLoadBrowserProcessSpecificV8SnapshotEnabled() + 13812 4 Electron Framework 0x10e2eab48 electron::fuses::IsLoadBrowserProcessSpecificV8SnapshotEnabled() + 28568 5 Electron Framework 0x10e2e9850 electron::fuses::IsLoadBrowserProcessSpecificV8SnapshotEnabled() + 23712 6 Electron Framework 0x10e3002c0 v8::internal::GetCurrentStackPosition() + 17616 7 Electron Framework 0x10e2fe218 v8::internal::GetCurrentStackPosition() + 9256 8 libsystem_malloc.dylib 0x18625fcc8 _malloc_zone_memalign + 284 9 libsystem_malloc.dylib 0x186242b68 posix_memalign + 40 10 llama-addon.node 0x130388e2c ggml_backend_metal_buffer_type_alloc_buffer + 152 11 llama-addon.node 0x1303719e8 ggml_backend_alloc_ctx_tensors_from_buft + 160 12 llama-addon.node 0x130398710 llama_new_context_with_model + 3276 13 llama-addon.node 0x130336af4 AddonContext::AddonContext(Napi::CallbackInfo const&) + 876 14 llama-addon.node 0x1303366d4 Napi::ObjectWrap::ConstructorCallbackWrapper(napi_env*, napi_callback_info)::'lambda0'()::operator()() const + 56
15 llama-addon.node 0x1303361b4 Napi::ObjectWrap::ConstructorCallbackWrapper(napi_env__ , napi_callback_info__) + 80
16 Electron Framework 0x114c6ee24 napi_is_detached_arraybuffer + 232
17 Electron Framework 0x10f349da4 v8::internal::Accessors::MakeAccessor(v8::internal::Isolate, v8::internal::Handle, void ()(v8::Local, v8::PropertyCallbackInfo const&), void ( )(v8::Local, v8::Local, v8::PropertyCallbackInfo const&)) + 13216
18 Electron Framework 0x10f34958c v8::internal::Accessors::MakeAccessor(v8::internal::Isolate, v8::internal::Handle, void ( )(v8::Local, v8::PropertyCallbackInfo const&), void ()(v8::Local, v8::Local, v8::PropertyCallbackInfo const&)) + 11144
19 ??? 0x157edd294 ???
20 ??? 0x157e4e57c ???
21 ??? 0x157fc0c78 ???
22 ??? 0x157e4d728 ???
23 ??? 0x157e4e438 ???
24 ??? 0x157fc0c78 ???
25 ??? 0x157e4d728 ???
26 ??? 0x157e883f4 ???
27 ??? 0x157f507b8 ???
28 ??? 0x157e762e8 ???
29 ??? 0x157e4aff8 ???
30 Electron Framework 0x10f418d00 v8::internal::Execution::Call(v8::internal::Isolate , v8::internal::Handle, v8::internal::Handle, int, v8::internal::Handle) + 3680
31 Electron Framework 0x10f4199b8 v8::internal::Execution::TryCallScript(v8::internal::Isolate, v8::internal::Handle, v8::internal::Handle, v8::internal::Handle, v8::internal::Execution::MessageHandling, v8::internal::MaybeHandle, bool) + 288
32 Electron Framework 0x10f419b24 v8::internal::Execution::TryCall(v8::internal::Isolate, v8::internal::Handle, v8::internal::Handle, int, v8::internal::Handle, v8::internal::Execution::MessageHandling, v8::internal::MaybeHandle , bool) + 200
33 Electron Framework 0x10f44c0e8 v8::internal::MicrotaskQueue::get(long) const + 496
34 Electron Framework 0x114c10148 node::CallbackScope::~CallbackScope() + 928
35 Electron Framework 0x114c104a4 node::CallbackScope::~CallbackScope() + 1788
36 Electron Framework 0x114c2402c node::EmitAsyncDestroy(node::Environment, node::async_context) + 61352
37 Electron Framework 0x114cc2f74 node::OnFatalError(char const, char const) + 32040
38 Electron Framework 0x114cc37a8 node::OnFatalError(char const, char const) + 34140
39 Electron Framework 0x114cb71e4 node::Buffer::New(v8::Isolate, char, unsigned long) + 142672
40 Electron Framework 0x10e0bd844 uv_random + 1416
41 Electron Framework 0x10e0c0c24 uv_async_send + 776
42 Electron Framework 0x10e0d1a9c uv_free_interface_addresses + 1512
43 Electron Framework 0x10e0c1068 uv_run + 272
44 Electron Framework 0x10e2653bc node::FreeArrayBufferAllocator(node::ArrayBufferAllocator) + 17572
45 Electron Framework 0x1113f085c node::GetArrayBufferAllocator(node::IsolateData) + 17552792
46 Electron Framework 0x11140de58 node::GetArrayBufferAllocator(node::IsolateData) + 17673108
47 Electron Framework 0x111457148 node::GetArrayBufferAllocator(node::IsolateData) + 17972868
48 Electron Framework 0x10e03c010 0x10de70000 + 1884176
49 Electron Framework 0x1114562a4 node::GetArrayBufferAllocator(node::IsolateData) + 17969120
50 CoreFoundation 0x1864fdcfc CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION + 28
51 CoreFoundation 0x1864fdc90 CFRunLoopDoSource0 + 176
52 CoreFoundation 0x1864fda00 CFRunLoopDoSources0 + 244
53 CoreFoundation 0x1864fc5f0 __CFRunLoopRun + 828
54 CoreFoundation 0x1864fbc5c CFRunLoopRunSpecific + 608
55 HIToolbox 0x190a77448 RunCurrentEventLoopInMode + 292
56 HIToolbox 0x190a770d8 ReceiveNextEventCommon + 220
57 HIToolbox 0x190a76fdc _BlockUntilNextEventMatchingListInModeWithFilter + 76
58 AppKit 0x189cd6be0 _DPSNextEvent + 660
59 AppKit 0x18a4ace8c -[NSApplication(NSEventRouting) _nextEventMatchingEventMask:untilDate:inMode:dequeue:] + 716
60 AppKit 0x189cca08c -[NSApplication run] + 476
61 Electron Framework 0x111457dfc node::GetArrayBufferAllocator(node::IsolateData) + 17976120
62 Electron Framework 0x111455c68 node::GetArrayBufferAllocator(node::IsolateData) + 17967524
63 Electron Framework 0x11140e9b8 node::GetArrayBufferAllocator(node::IsolateData) + 17676020
64 Electron Framework 0x1113d55a0 node::GetArrayBufferAllocator(node::IsolateData) + 17441500
65 Electron Framework 0x1105673b4 node::GetArrayBufferAllocator(node::IsolateData) + 2310384
66 Electron Framework 0x110568e4c node::GetArrayBufferAllocator(node::IsolateData) + 2317192
67 Electron Framework 0x110564d24 node::GetArrayBufferAllocator(node::IsolateData) + 2300512
68 Electron Framework 0x10e402410 v8::internal::compiler::BasicBlock::set_loop_header(v8::internal::compiler::BasicBlock) + 13948
69 Electron Framework 0x10e403578 v8::internal::compiler::BasicBlock::set_loop_header(v8::internal::compiler::BasicBlock) + 18404
70 Electron Framework 0x10e4033a8 v8::internal::compiler::BasicBlock::set_loop_header(v8::internal::compiler::BasicBlock) + 17940
71 Electron Framework 0x10e401c54 v8::internal::compiler::BasicBlock::set_loop_header(v8::internal::compiler::BasicBlock) + 11968
72 Electron Framework 0x10e401df4 v8::internal::compiler::BasicBlock::set_loop_header(v8::internal::compiler::BasicBlock) + 12384
73 Electron Framework 0x10e0d22f0 ElectronMain + 128
74 dyld 0x1860a50e0 start + 2360
Thread 1: 0 libsystem_pthread.dylib 0x18641be28 start_wqthread + 0
Thread 2: 0 libsystem_pthread.dylib 0x18641be28 start_wqthread + 0
Thread 3:: ThreadPoolServiceThread 0 libsystem_kernel.dylib 0x1863ec808 kevent64 + 8 1 Electron Framework 0x111461904 node::GetArrayBufferAllocator(node::IsolateData) + 18015808 2 Electron Framework 0x111461138 node::GetArrayBufferAllocator(node::IsolateData) + 18013812 3 Electron Framework 0x11140e9b8 node::GetArrayBufferAllocator(node::IsolateData) + 17676020 4 Electron Framework 0x1113d55a0 node::GetArrayBufferAllocator(node::IsolateData) + 17441500 5 Electron Framework 0x11142fbc4 node::GetArrayBufferAllocator(node::IsolateData) + 17811712 6 Electron Framework 0x11141855c node::GetArrayBufferAllocator(node::IsolateData) + 17715864 7 Electron Framework 0x11142fd04 node::GetArrayBufferAllocator(node::IsolateData) + 17812032 8 Electron Framework 0x111443418 node::GetArrayBufferAllocator(node::IsolateData) + 17891668 9 libsystem_pthread.dylib 0x186421034 _pthread_start + 136 10 libsystem_pthread.dylib 0x18641be3c thread_start + 8
Happy to debug, and provide more info before you dive in.