helloadhavan/github_issues huggingface dataset:
Repository: huggingface/transformers
Pull request: Cheap CLI

Better guard the CLI commands, so that `transformers add-new-model-like` works without the serving dependencies (bug) and so that `transformers chat` does not import `torch` unnecessarily (improvement)

The `transformers run` (previously `transformers-cli run`) is an artefact of the past, was not documented nor tested,
and isn't part of any public documentation. Removing it for now and writing about it in the migration guide.

Changed files:
filename: MIGRATION_GUIDE_V5.md
patch: @@ -265,6 +265,8 @@ The `transformers run` (previously `transformers-cli run`) is an artefact of the
 and isn't part of any public documentation. We're removing it for now and ask you to please let us know in case
 this is a method you are using; in which case we should bring it back with better support.
 
+Linked PR: https://github.com/huggingface/transformers/pull/42447
+
 ## Environment variables
 
 - Legacy environment variables like `TRANSFORMERS_CACHE`, `PYTORCH_TRANSFORMERS_CACHE`, and `PYTORCH_PRETRAINED_BERT_CACHE` have been removed. Please use `HF_HOME` instead.
Repository: vuejs/vue
Pull request: fix v-bind.prop parse (fix #4432)

fix #4432

Changed files:
filename: src/compiler/parser/index.js
patch: @@ -414,6 +414,7 @@ function processAttrs (el) {
       if (bindRE.test(name)) { // v-bind
         name = name.replace(bindRE, '')
         value = parseFilters(value)
+        isProp = false
         if (modifiers) {
           if (modifiers.prop) {
             isProp = true

filename: test/unit/features/directives/bind.spec.js
patch: @@ -121,6 +121,18 @@ describe('Directive v-bind', () => {
     expect(vm.$el.children[1].innerHTML).toBe('<span>qux</span>')
   })
 
+  it('.prop modifier with normal attribute binding', () => {
+    const vm = new Vue({
+      template: '<input :some.prop="some" :id="id">',
+      data: {
+        some: 'hello',
+        id: false
+      }
+    }).$mount()
+    expect(vm.$el.some).toBe('hello')
+    expect(vm.$el.getAttribute('id')).toBe(null)
+  })
+
   it('.camel modifier', () => {
     const vm = new Vue({
       template: '<svg :view-box.camel="viewBox"></svg>',
Repository: ollama/ollama
Pull request: server: reduce max connections used in download

The previous value of 64 was WAY too high and unnecessary. It reached diminishing returns and blew past it. This is a more reasonable number for _most_ normal cases. For users on cloud servers with excellent network quality, this will keep screaming for them, without hitting our CDN limits. For users with relatively poor network quality, this will keep them from saturating their network and causing other issues.

Changed files:
filename: server/download.go
patch: @@ -94,7 +94,7 @@ func (p *blobDownloadPart) UnmarshalJSON(b []byte) error {
 }
 
 const (
-	numDownloadParts          = 64
+	numDownloadParts          = 16
 	minDownloadPartSize int64 = 100 * format.MegaByte
 	maxDownloadPartSize int64 = 1000 * format.MegaByte
 )
Repository: ggml-org/llama.cpp
Pull request: mtmd: add min/max pixels gguf metadata

Some on-going PRs already using this, but were blocked from merging for unrelated reasons.

This PR adds this metadata, so future PRs can be merged without too many conflicts.

Changed files:
filename: gguf-py/gguf/constants.py
patch: @@ -284,6 +284,8 @@ class Clip:
     class ClipVision:
         PROJECTOR_TYPE      = "clip.vision.projector_type" # for mixed modality models
         IMAGE_SIZE          = "clip.vision.image_size"
+        IMAGE_MIN_PIXELS    = "clip.vision.image_min_pixels"
+        IMAGE_MAX_PIXELS    = "clip.vision.image_max_pixels"
         PREPROC_IMAGE_SIZE  = "clip.vision.preproc_image_size"
         PATCH_SIZE          = "clip.vision.patch_size"
         EMBEDDING_LENGTH    = "clip.vision.embedding_length"

filename: gguf-py/gguf/gguf_writer.py
patch: @@ -1113,6 +1113,12 @@ def add_vision_attention_layernorm_eps(self, value: float) -> None:
     def add_vision_image_size(self, value: int) -> None:
         self.add_uint32(Keys.ClipVision.IMAGE_SIZE, value)
 
+    def add_vision_max_pixels(self, value: int) -> None:
+        self.add_uint32(Keys.ClipVision.IMAGE_MAX_PIXELS, value)
+
+    def add_vision_min_pixels(self, value: int) -> None:
+        self.add_uint32(Keys.ClipVision.IMAGE_MIN_PIXELS, value)
+
     def add_vision_preproc_image_size(self, value: int) -> None:
         self.add_uint32(Keys.ClipVision.PREPROC_IMAGE_SIZE, value)
 

filename: tools/mtmd/clip-impl.h
patch: @@ -36,6 +36,8 @@
 // vision-specific
 #define KEY_VISION_PROJ_TYPE    "clip.vision.projector_type" // for models with mixed modalities
 #define KEY_IMAGE_SIZE          "clip.vision.image_size"
+#define KEY_IMAGE_MIN_PIXELS    "clip.vision.image_min_pixels"
+#define KEY_IMAGE_MAX_PIXELS    "clip.vision.image_max_pixels"
 #define KEY_PREPROC_IMAGE_SIZE  "clip.vision.preproc_image_size"
 #define KEY_PATCH_SIZE          "clip.vision.patch_size"
 #define KEY_IMAGE_MEAN          "clip.vision.image_mean"
Repository: huggingface/transformers
Pull request: Fix an edge case for `get_encoder()`

# What does this PR do?

As per title, fixes https://github.com/huggingface/transformers/pull/42156#issuecomment-3553776255 and adjusts the test case slightly

I didn't not change the setter, we don't call `set_encoder` unless we're sure there is an encoder right?


Changed files:
filename: src/transformers/modeling_utils.py
patch: @@ -2030,7 +2030,11 @@ def get_encoder(self, modality: Optional[str] = None):
                 return getattr(self, name)
 
         if self.base_model is not self and hasattr(self.base_model, "get_encoder"):
-            return self.base_model.get_encoder(modality=modality)
+            base_encoder = self.base_model.get_encoder(modality=modality)
+            # Base model will always have attr `get_encoder` if inherited from `PreTrainedModel`
+            # But it doesn't mean that the model has an encoder module, and we need to return `self`
+            if base_encoder != self.base_model:
+                return base_encoder
 
         # If this is a base transformer model (no encoder/model attributes), return self
         return self

filename: tests/utils/test_modeling_utils.py
patch: @@ -3233,7 +3233,7 @@ def test_decoder_only_model_returns_self(self):
             num_hidden_layers=2,
             num_attention_heads=4,
         )
-        model = MistralModel(cfg)
+        model = MistralForCausalLM(cfg)
         encoder = model.get_encoder()
 
         assert encoder is model, f"Base model get_encoder() should return self, got {type(encoder)}"
Repository: nodejs/node
Pull request: tls: fix leak on invalid protocol method

Unfortunately looks like this can happen with an invalid `secureProtocol` as well - if validation fails in `SecureContext::Init`, `Reset` would be called via dtor but `ctx_` would still be nullptr so `env()->external_memory_accounter()->Decrease` wouldn't be called, leading to the same stacktrace as https://github.com/nodejs/node/pull/60390.

Please let me know if there's a better fix here.

<!--
Before submitting a pull request, please read:

- the CONTRIBUTING guide at https://github.com/nodejs/node/blob/HEAD/CONTRIBUTING.md
- the commit message formatting guidelines at
  https://github.com/nodejs/node/blob/HEAD/doc/contributing/pull-requests.md#commit-message-guidelines

For code changes:
1. Include tests for any bug fixes or new features.
2. Update documentation if relevant.
3. Ensure that `make -j4 test` (UNIX), or `vcbuild test` (Windows) passes.

If you believe this PR should be highlighted in the Node.js CHANGELOG
please add the `notable-change` label.

Developer's Certificate of Origin 1.1

By making a contribution to this project, I certify that:

(a) The contribution was created in whole or in part by me and I
    have the right to submit it under the open source license
    indicated in the file; or

(b) The contribution is based upon previous work that, to the best
    of my knowledge, is covered under an appropriate open source
    license and I have the right under that license to submit that
    work with modifications, whether created in whole or in part
    by me, under the same open source license (unless I am
    permitted to submit under a different license), as indicated
    in the file; or

(c) The contribution was provided directly to me by some other
    person who certified (a), (b) or (c) and I have not modified
    it.

(d) I understand and agree that this project and the contribution
    are public and that a record of the contribution (including all
    personal information I submit with it, including my sign-off) is
    maintained indefinitely and may be redistributed consistent with
    this project or the open source license(s) involved.
-->


Changed files:
filename: src/crypto/crypto_context.cc
patch: @@ -1351,7 +1351,6 @@ SecureContext* SecureContext::Create(Environment* env) {
 SecureContext::SecureContext(Environment* env, Local<Object> wrap)
     : BaseObject(env, wrap) {
   MakeWeak();
-  env->external_memory_accounter()->Increase(env->isolate(), kExternalSize);
 }
 
 inline void SecureContext::Reset() {
@@ -1469,6 +1468,8 @@ void SecureContext::Init(const FunctionCallbackInfo<Value>& args) {
   if (!sc->ctx_) {
     return ThrowCryptoError(env, ERR_get_error(), "SSL_CTX_new");
   }
+
+  env->external_memory_accounter()->Increase(env->isolate(), kExternalSize);
   SSL_CTX_set_app_data(sc->ctx_.get(), sc);
 
   // Disable SSLv2 in the case when method == TLS_method() and the
Repository: facebook/react
Pull request: [ci] Fix typo


yml was a mistake


Changed files:
filename: .github/workflows/shared_check_maintainer.yml
patch: @@ -38,7 +38,7 @@ jobs:
               isRemote = isRemote === 'true';
             }
             if (typeof isRemote !== 'boolean') {
-              throw new Error(`Invalid `isRemote` input. Expected a boolean, got: ${isRemote}`);
+              throw new Error(`Invalid \`isRemote\` input. Expected a boolean, got: ${isRemote}`);
             }
 
             let content = null;
Repository: vuejs/vue
Pull request: More informative warning message for comp name (closes #4428)

This commit adds a more informative warning message for invalid component names. Also fixes a typo.

Changed files:
filename: src/core/global-api/extend.js
patch: @@ -28,7 +28,8 @@ export function initExtend (Vue: GlobalAPI) {
       if (!/^[a-zA-Z][\w-]*$/.test(name)) {
         warn(
           'Invalid component name: "' + name + '". Component names ' +
-          'can only contain alphanumeric characaters and the hyphen.'
+          'can only contain alphanumeric characters and the hyphen, ' +
+          'and must start with a letter.'
         )
       }
     }

filename: test/unit/features/options/name.spec.js
patch: @@ -15,7 +15,16 @@ describe('Options name', () => {
     })
 
     /* eslint-disable */
-    expect(`Invalid component name: "Hyper*Vue". Component names can only contain alphanumeric characaters and the hyphen.`)
+    expect(`Invalid component name: "Hyper*Vue". Component names can only contain alphanumeric characters and the hyphen, and must start with a letter.`)
+      .toHaveBeenWarned()
+    /* eslint-enable */
+
+    Vue.extend({
+      name: '2Cool2BValid'
+    })
+
+    /* eslint-disable */
+    expect(`Invalid component name: "2Cool2BValid". Component names can only contain alphanumeric characters and the hyphen, and must start with a letter.`)
       .toHaveBeenWarned()
     /* eslint-enable */
   })
Repository: ollama/ollama
Pull request: fix: Add tooltip to system tray icon

- Updated setIcon method to include tooltip text for the system tray icon.
- Added NIF_TIP flag and set the tooltip text using UTF16 encoding.

Resolves: #6372

Changed files:
filename: app/tray/wintray/tray.go
patch: @@ -11,6 +11,7 @@ import (
 	"path/filepath"
 	"sort"
 	"sync"
+	"syscall"
 	"unsafe"
 
 	"golang.org/x/sys/windows"
@@ -433,7 +434,12 @@ func (t *winTray) setIcon(src string) error {
 	t.muNID.Lock()
 	defer t.muNID.Unlock()
 	t.nid.Icon = h
-	t.nid.Flags |= NIF_ICON
+	t.nid.Flags |= NIF_ICON | NIF_TIP
+	if toolTipUTF16, err := syscall.UTF16FromString(commontray.ToolTip); err == nil {
+		copy(t.nid.Tip[:], toolTipUTF16)
+	} else {
+		return err
+	}
 	t.nid.Size = uint32(unsafe.Sizeof(*t.nid))
 
 	return t.nid.modify()

filename: app/tray/wintray/w32api.go
patch: @@ -61,6 +61,7 @@ const (
 	MIIM_SUBMENU        = 0x00000004
 	MIM_APPLYTOSUBMENUS = 0x80000000
 	NIF_ICON            = 0x00000002
+	NIF_TIP             = 0x00000004
 	NIF_INFO            = 0x00000010
 	NIF_MESSAGE         = 0x00000001
 	SW_HIDE             = 0
Repository: huggingface/transformers
Pull request: [fp8] fix scales param name

# What does this PR do?



Changed files:
filename: src/transformers/integrations/finegrained_fp8.py
patch: @@ -409,14 +409,14 @@ def __init__(self, config, block_size, device):
             # gate_up tiles: ceil(Wg_out/bo) x ceil(Wg_in/bi)
             gu_scale_o = _ceil_div(Wg_out, bo)
             gu_scale_i = _ceil_div(Wg_in, bi)
-            self.gate_up_proj_scales_inv = nn.Parameter(
+            self.gate_up_proj_scale_inv = nn.Parameter(
                 torch.zeros(self.num_experts, gu_scale_o, gu_scale_i, dtype=torch.float32, device=device)
             )
 
             # down tiles: ceil(Wd_out/bo) x ceil(Wd_in/bi)
             dp_scale_o = _ceil_div(Wd_out, bo)
             dp_scale_i = _ceil_div(Wd_in, bi)
-            self.down_proj_scales_inv = nn.Parameter(
+            self.down_proj_scale_inv = nn.Parameter(
                 torch.zeros(self.num_experts, dp_scale_o, dp_scale_i, dtype=torch.float32, device=device)
             )
         else:
@@ -452,11 +452,11 @@ def forward(
             _, token_idx = torch.where(expert_mask[expert_idx])
             current_state = hidden_states.index_select(0, token_idx)
             gate, up = self.linear(
-                current_state, self.gate_up_proj[expert_idx], self.gate_up_proj_scales_inv[expert_idx]
+                current_state, self.gate_up_proj[expert_idx], self.gate_up_proj_scale_inv[expert_idx]
             ).chunk(2, dim=-1)
             current_hidden_states = self.act_fn(gate) * up
             current_hidden_states = self.linear(
-                current_hidden_states, self.down_proj[expert_idx], self.down_proj_scales_inv[expert_idx]
+                current_hidden_states, self.down_proj[expert_idx], self.down_proj_scale_inv[expert_idx]
             )
 
             routing_weights = top_k_weights[token_idx, expert_idx].unsqueeze(-1)
@@ -643,7 +643,7 @@ def convert(self, input_dict: torch.Tensor, **kwargs) -> dict[str, torch.Tensor]
         if target_keys.endswith("weight"):
             scale_key = target_keys.rsplit(".", 1)[0] + ".weight_scale_inv"
         else:
-            scale_key = target_keys + "_scales_inv"
+            scale_key = target_keys + "_scale_inv"
 
         # Return both quantized weights and per-tile inverse scales (keeps leading dims, e.g., num_experts)
         return {
Repository: ggml-org/llama.cpp
Pull request: server: print actual model name in 'model not found" error

Experimenting with AI, my environment gets messy fast and it's not always easy to know what model my software is trying to load. This helps with troubleshooting.


Before:

```
> Who are you ?


Error: {
  code = 400,
  message = "model not found",
  type = "invalid_request_error"
}
```

after

```
> Who are you ?


Error: {
  code = 400,
  message = "model 'toto' is not found",
  type = "invalid_request_error"
}
```


NB: I couldn't find a target to run linting (usually `make lint` / or `make format`) so tried to run the CI locally as explained  in contributing.md with 
```
GG_BUILD_CUDA=1 bash ./ci/run.sh ./tmp/results ./tmp/mnt
Warning: Using fallback CUDA architectures
./ci/run.sh: ligne 651: python3 : commande introuvable
```
I am developing from within the repo flake.nix so I expected all devtools present (I noticed the flake didn't provide ccache either, not sure if that's a conscious decision or not). I can submit a patch to add python3.

*Make sure to read the [contributing guidelines](https://github.com/ggml-org/llama.cpp/blob/master/CONTRIBUTING.md) before submitting a PR*


Changed files:
filename: tools/server/server-models.cpp
patch: @@ -767,7 +767,7 @@ static bool router_validate_model(const std::string & name, server_models & mode
     }
     auto meta = models.get_meta(name);
     if (!meta.has_value()) {
-        res_err(res, format_error_response("model not found", ERROR_TYPE_INVALID_REQUEST));
+        res_err(res, format_error_response(string_format("model '%s' not found", name.c_str()), ERROR_TYPE_INVALID_REQUEST));
         return false;
     }
     if (models_autoload) {
Repository: facebook/react
Pull request: [ci] Make maintainer check workflow usable from other repositories


For use in reactjs/react.dev


Changed files:
filename: .github/workflows/shared_check_maintainer.yml
patch: @@ -6,6 +6,10 @@ on:
       actor:
         required: true
         type: string
+      is_remote:
+        required: false
+        type: boolean
+        default: false
     outputs:
       is_core_team:
         value: ${{ jobs.check_maintainer.outputs.is_core_team }}
@@ -29,8 +33,30 @@ jobs:
           script: |
             const fs = require('fs');
             const actor = '${{ inputs.actor }}';
-            const data = await fs.readFileSync('./MAINTAINERS', { encoding: 'utf8' });
-            const maintainers = new Set(data.split('\n'));
+            const isRemote = ${{ inputs.is_remote }};
+
+            let content = null;
+            if (isRemote === true) {
+              const res = await github.rest.repos.getContent({
+                owner: 'facebook',
+                repo: 'react',
+                path: 'MAINTAINERS',
+                ref: 'main',
+                headers: { Accept: 'application/vnd.github+json' }
+              });
+              if (res.status !== 200) {
+                console.error(res);
+                throw new Error('Unable to fetch MAINTAINERS file');
+              }
+              content = Buffer.from(res.data.content, 'base64').toString();
+            } else {
+              content = await fs.readFileSync('./MAINTAINERS', { encoding: 'utf8' });
+            }
+            if (content === null) {
+              throw new Error('Unable to retrieve local or http MAINTAINERS file');
+            }
+
+            const maintainers = new Set(content.split('\n'));
             if (maintainers.has(actor)) {
               console.log(`🟢 ${actor} is a maintainer`);
               return true;
Repository: vuejs/vue
Pull request: Add `parsePlatformTagName` config

 > As described in [How to implement the `<div>` component on the web](https://github.com/weexteam/weex-vue-framework/issues/12), this is a way to achieve solution 1.

### Notes

Add a global configuration function `parsePlatformTagName` to be able to parse the real tag name for the specific platform. It takes a string and return it directly by default.

This function should be used in conjunction with `isReservedTag`.



Changed files:
filename: src/core/config.js
patch: @@ -12,6 +12,7 @@ export type Config = {
   keyCodes: { [key: string]: number };
   // platform
   isReservedTag: (x?: string) => boolean;
+  parsePlatformTagName: (x: string) => string;
   isUnknownElement: (x?: string) => boolean;
   getTagNamespace: (x?: string) => string | void;
   mustUseProp: (tag?: string, x?: string) => boolean;
@@ -69,6 +70,11 @@ const config: Config = {
    */
   getTagNamespace: noop,
 
+  /**
+   * Parse the real tag name for the specific platform.
+   */
+  parsePlatformTagName: (x: string): string => x,
+
   /**
    * Check if an attribute must be bound using property, e.g. value
    * Platform-dependent.

filename: src/core/vdom/create-element.js
patch: @@ -61,7 +61,7 @@ export function _createElement (
     if (config.isReservedTag(tag)) {
       // platform built-in elements
       vnode = new VNode(
-        tag, data, children,
+        config.parsePlatformTagName(tag), data, children,
         undefined, undefined, context
       )
     } else if ((Ctor = resolveAsset(context.$options, 'components', tag))) {
Repository: nodejs/node
Pull request: doc: add haramj as triager

I would like to apply to be a triager for this project.

I am eager to become more deeply involved in the community by helping to classify issues and lead discussions. My goal is to build trust through consistent activity, with the ultimate aim of becoming a Node.js Collaborator.

I have been an active contributor with several merged PRs. My contributions include:

- Improving documentation and error messages for clarity (e.g., `fs.readFile()`).
- Adding new features and options, such as `${pid}` placeholder support in `-cpu-prof-name` and configurable `keepAliveTimeoutBuffer` options for `http.Server` and `http.Agent`.
- Resolving `TODO`s and refactoring code for stability, such as preventing an overflow in `myersDiff` and replacing unsafe `for-of` loops to align with project guidelines.

I have read the Code of Conduct and swear to abide by it.

Thank you for your consideration.

<!--
Before submitting a pull request, please read:

- the CONTRIBUTING guide at https://github.com/nodejs/node/blob/HEAD/CONTRIBUTING.md
- the commit message formatting guidelines at
  https://github.com/nodejs/node/blob/HEAD/doc/contributing/pull-requests.md#commit-message-guidelines

For code changes:
1. Include tests for any bug fixes or new features.
2. Update documentation if relevant.
3. Ensure that `make -j4 test` (UNIX), or `vcbuild test` (Windows) passes.

If you believe this PR should be highlighted in the Node.js CHANGELOG
please add the `notable-change` label.

Developer's Certificate of Origin 1.1

By making a contribution to this project, I certify that:

(a) The contribution was created in whole or in part by me and I
    have the right to submit it under the open source license
    indicated in the file; or

(b) The contribution is based upon previous work that, to the best
    of my knowledge, is covered under an appropriate open source
    license and I have the right under that license to submit that
    work with modifications, whether created in whole or in part
    by me, under the same open source license (unless I am
    permitted to submit under a different license), as indicated
    in the file; or

(c) The contribution was provided directly to me by some other
    person who certified (a), (b) or (c) and I have not modified
    it.

(d) I understand and agree that this project and the contribution
    are public and that a record of the contribution (including all
    personal information I submit with it, including my sign-off) is
    maintained indefinitely and may be redistributed consistent with
    this project or the open source license(s) involved.
-->


Changed files:
filename: README.md
patch: @@ -755,6 +755,8 @@ maintaining the Node.js project.
   **Gireesh Punathil** <<gpunathi@in.ibm.com>> (he/him)
 * [gurgunday](https://github.com/gurgunday) -
   **Gürgün Dayıoğlu** <<hey@gurgun.day>>
+* [haramj](https://github.com/haramj) -
+  **Haram Jeong** <<haramj.dev@gmail.com>>
 * [HBSPS](https://github.com/HBSPS) -
   **Wiyeong Seo** <<hbsps.dev@gmail.com>>
 * [iam-frankqiu](https://github.com/iam-frankqiu) -