text:
# Remote Inventory Federation

This feature would add the ability to Kapitan to fetch parts of the inventory from remote locations (https/git). This would allow users to combine different inventories from different sources and build modular infrastructure reusable across various repos.

Author: @alpharoy14

## Specification

The configuration and declaration of remote inventories would be done in the inventory files.

The file specifications are as follows:

```yaml
parameters:
 kapitan:
  inventory:
   - type: <inventory_type> #git\https
     source: <source_of_inventory>
     output_path: <relative_output_path>
```

On executing the ```$ kapitan compile --fetch``` command, first the remote inventories will be fetched followed by fetching of external dependencies and finally merge the inventory to compile.

## Copying inventory files to the output location

The output path is the path to save the inventory items into. The path is relative to the `inventory/` directory. For example, it could be `/classes/`. The contents of the fetched inventory will be recursively copied.

The fetched inventory files will be cached in the `.dependency_cache` directory if `--cache` is set.
eg. `$ kapitan compile --fetch --cache`

## Force fetching

While fetching, the output path will be recursively checked to see if it contains any file with the same name. If so, kapitan will skip fetching it.

To overwrite the files with the newly downloaded inventory items, we can add the `--force-fetch` flag to the compile command, as shown below.

`$ kapitan compile --force-fetch`

## URL type

The URL type can be either git or http(s). Depending on the URL type, the configuration file may have additional arguments.

E.g Git type may also include aditional `ref` parameter as illustrated below:

```yaml
inventory:
 - type: git #git\https
   source: <source_of_inventory>
   output_path: <output_path>
   ref: <commit_hash/branch/tag>
```

## Implementation details

TODO

### Dependencies

- [GitPython](https://github.com/gitpython-developers/GitPython) module (and git executable) for git type
- requests module for http[s]

repository: kapicorp/kapitan

repo_name: kapicorp/kapitan


text:
# Kafka in Docker

This repository provides everything you need to run Kafka in Docker.

## Disclaimer

This isn't production grade nor is it intended for production usage. This image doesn't setup any volumes to persist data
or other fault tolerance mechanism, and running kafka and zookeeper on the same host is really a bad idea.

Also note that this image runs as `root`, so it's *really* a bad idea to run it anywhere other than local development boxes.

It's intended mostly for development and prototyping, when you need a local kafka instance without all the shebang.

## Why?

The main hurdle of running Kafka in Docker is that it depends on Zookeeper.
Compared to other Kafka docker images, this one runs both Zookeeper and Kafka
in the same container. This means:

* No dependency on an external Zookeeper host, or linking to another container
* Zookeeper and Kafka are configured to work together out of the box

## What's included?

* `zookeeper`, version `3.4.9-3+deb9u1`. It's the latest stable in debian's stretch [repos](https://packages.debian.org/stretch/zookeeper).
* `kafka`, version 2.1.0, scala 2.12 [link](https://kafka.apache.org/downloads#2.1.0)
* `wget`
* `netcat`
* `supervisor`

## Run

```bash
docker run -p 2181:2181 -p 9092:9092 --env ADVERTISED_HOST=`docker-machine ip \`docker-machine active\`` --env ADVERTISED_PORT=9092 nuvo/docker-kafka
```

## Examples

See the examples folder for:
* `docker-compose.yaml`
* `kubernetes.yaml`

```bash
export KAFKA=`docker-machine ip \`docker-machine active\``:9092
kafka-console-producer.sh --broker-list $KAFKA --topic test
```

```bash
export ZOOKEEPER=`docker-machine ip \`docker-machine active\``:2181
kafka-console-consumer.sh --zookeeper $ZOOKEEPER --topic test
```

## Public Builds

https://registry.hub.docker.com/u/nuvo/docker-kafka

Build from Source

```bash
docker build -t nuvo/docker-kafka .
```

repository: nuvo/docker-kafka

branch_name: refs/heads/master

extension: md

license_type: permissive

repo_name: nuvo/docker-kafka


text:
# raspberry-pi 2 debian qemu

Nearly a straight copy of [the armv7 version from Redis](https://github.com/resin-io-projects/armv7hf-debian-qemu) just modified to use Raspbian as the base image.


text:
# ewd-memory-globals: Memory emulation of Global Storage database

[![Build Status](https://travis-ci.org/killmenot/ewd-memory-globals.svg?branch=master)](https://travis-ci.org/killmenot/ewd-memory-globals) [![Coverage Status](https://coveralls.io/repos/github/killmenot/ewd-memory-globals/badge.svg?branch=master)](https://coveralls.io/github/killmenot/ewd-memory-globals?branch=master) [![dependencies Status](https://david-dm.org/github/killmenot/status.svg)](https://david-dm.org/github/killmenot) [![devDependencies Status](https://david-dm.org/killmenot/ewd-memory-globals/dev-status.svg)](https://david-dm.org/killmenot/ewd-memory-globals?type=dev) [![npm version](https://img.shields.io/npm/v/ewd-memory-globals.svg)](https://www.npmjs.com/package/ewd-memory-globals) [![Known Vulnerabilities](https://snyk.io/test/github/killmenot/ewd-memory-globals/badge.svg?targetFile=package.json)](https://snyk.io/test/github/killmenot/ewd-memory-globals?targetFile=package.json)

Google Group for discussions, support, advice etc: [http://groups.google.co.uk/group/enterprise-web-developer-community](http://groups.google.co.uk/group/enterprise-web-developer-community)

Special thanks to the Ripple Foundation [http://rippleosi.org](http://rippleosi.org) for support and funding of this project.

## ewd-memory-globals

This module provides an emulation of a Global Storage database using memory storage.

The APIs are modelled on the *cache.node* interface provided by the Caché database (a proprietary Global Storage database) and are designed to behave identically.

It is designed to be used in conjunction with the [ewd-qoper8](https://github.com/robtweed/ewd-qoper8) module and used within  its worker processes, where synchronous database access does not interfere with the main Node.js process, rather than in conventional Node.js-based applications.

See [https://robtweed.wordpress.com/2016/03/03/higher-level-database-operations-with-node-js/](https://robtweed.wordpress.com/2016/03/03/higher-level-database-operations-with-node-js/) for further background.

## APIs

The following APIs are provided:

    open()
    close()
    get()
    set()
    data()
    increment()
    kill()
    next()
    previous()
    next_node()
    previous_node()
    lock()
    unlock()
    global_directory()
    version()

## Examples

Several examples demonstrating the use of *ewd-memory-globals* are included in the */examples* folder.

In addition to basic API tests, you can also see how the *ewd-document-store* module provides a high-level abstraction of *ewd-memory-global's* Global Storage as:

- persistent JavaScript Objects
- document database

See /examples/docstore-tests.js

For more information on ewd-document-store, see:

[http://gradvs1.mgateway.com/download/ewd-document-store.pdf](http://gradvs1.mgateway.com/download/ewd-document-store.pdf)

You'll also find a detailed set of presentations on Global Storage databases and the
ewd-document-store JavaScript abstraction on the M/Gateway Web Site: go to:

      [http://www.mgateway.com](http://www.mgateway.com)

Click the *Training* tab.  Parts 17 to 27 will provide in-depth background. *ewd-memory-globals* will behave
identically to the other Global Storage databases referred to in these presentations.

## How Global Storage is Emulated in ewd-memory-globals

To understand the basics of a Global Storage database, see

[http://www.slideshare.net/robtweed/ewd-3-training-course-part-17-introduction-to-global-storage-databases](http://www.slideshare.net/robtweed/ewd-3-training-course-part-17-introduction-to-global-storage-databases)

The hierarchical structure of a Global is emulated using plain JavaScript object

 - node:xxxx  A hash that contains details about each Global Node, specifically whether it's a leaf-node or not, and if so, its value
 - children:xxxx  A sorted list containing any child subscript values for each of a Global's nodes
 - leaves:xxxx  A sorted list containing pointers to the node: keys for leaf nodes only

A global node key (xxxx) is constructed from the Global name and its Subscripts.  They are flattened into
a singe string using Hex 01 as a delimiter.  For example the Global Node:

      rob("a","b","c")

would be represented as:

      rob\x01a\x01b\x01\c

In order to emulate the subscript collating order of Global Storage database, integer subscript values
are padded out with up to 9 leading zeros within the children:xxxx sorted lists.

The Lock and Unlock commands are emulated using the Redis Blocking Pop command BLPOP and use two additional
simple keys:

- lock:xxxx  Representing the Global Node that is locked
- locker: xxxx  Representing the process locking the node

## License

The MIT License (MIT)

    Copyright (c) Alexey Kucherenko

    Permission is hereby granted, free of charge, to any person obtaining a copy
    of this software and associated documentation files (the "Software"), to deal
    in the Software without restriction, including without limitation the rights
    to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
    copies of the Software, and to permit persons to whom the Software is
    furnished to do so, subject to the following conditions:

    The above copyright notice and this permission notice shall be included in all
    copies or substantial portions of the Software.

     IN NO EVENT SHALL THE
    AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
    LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
    OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
    SOFTWARE.

license: MIT

repository: killmenot/ewd-memory-globals

repo_name: killmenot/ewd-memory-globals


text:
# Options

Set shell options in a script or at a global level.

## Prevent accidental file overwrites

### Copy and move

[source](https://unix.stackexchange.com/questions/452865/are-there-any-disadvantages-of-setting-noclobber)

```sh
alias cp='cp -i'
alias mv='mv -i'
```

### Redirection

> Prevent output redirection using ‘>’, ‘>&’, and ‘<>’ from overwriting existing files. [source](https://www.gnu.org/software/bash/manual/html_node/The-Set-Builtin.html#The-Set-Builtin)

```sh
set -C
```

Similar to the above. [source](https://www.cyberciti.biz/tips/howto-keep-file-safe-from-overwriting.html)

```sh
set -o noclobber
```

When this is on, `> file` gives an error but `>| file` seems to force but need to confirm.

## Exit on error

- Using `set` [docs](https://www.gnu.org/software/bash/manual/html_node/The-Set-Builtin.html#The-Set-Builtin).
    ```sh
    set -e

    # Reverse it with this:
    set +e
    ```
- In a shebang. Only works with `#!/bin/bash` and not `#!/usr/bin/env bash`.
    ```sh
    #!/bin/bash -e

    echo 'Hello!'
    ```
- Setting the body of the script.
    ```sh
    #!/usr/bin/env bash

    set -e
    echo 'Hello!'
    ```

## Verbose

Print a trace of commands before running.

```sh
set -x
```

Or

```sh
$ bash -x my_script.sh
```

gha_language: Makefile

gha_license_id: MIT


text:
# Description: Write here

## Write here
------------------------------------- Bayes Theorem (Positive)
Prior = P(C)

Sensitivity = P(Positive | C)               1 - Sensitivity
Specivity   = P(Negative | Not C)           1 - Specivity

P(C, Positive) = P(C) * P(Positive | C)                 - I
P(Not C, Positive) = P(Not C) * P(Positive | Not C)     - II
P(Positive) = I + II

P(C | Positive) = I / P(Positive)
P(Not C | Positive) = II / P(Positive)

------------------------------------- Bayes Theorem (Negative)
Prior = P(C)

Sensitivity = P(Negative | C)
Specivity   = P(Negative | Not C)

P(C, Negative) = P(C) * P(Negative | C)                 - I
P(Not C, Negative) = P(Not C) * P(Negative | Not C)     - II
P(Negative) = I + II

P(C | Negative) = I / P(Negative)
P(Not C | Negative) = II / P(Negative)
------------------------------------- Go From Below
Given: P(Home) or P(Gone) or both
Given: P(Rain|Home)
Given: P(Rain|Gone)

P(Home, Rain) = P(Home) * P(Rain | Home) = .4*.01= .004
P(Gone, Rain) = P(Gone) * P(Rain | Not Home) = .6*.3 = .18
P(Rain) = .184

P(Home|Rain) = P(Home, Rain) / P(Rain) = .004/.184

### Usage

#### Note
- None

##### TODO
- None

branch_name: refs/heads/develop

gha_language: R


text:
## Tenth Line
### Illustrate
<https://leetcode.com/problems/tenth-line>

Given a text file file.txt, print just the 10th line of the file.

### Input - `file.txt`

```
Line 1
Line 2
Line 3
Line 4
Line 5
Line 6
Line 7
Line 8
Line 9
Line 10
```

### Output
```
Line 10
```

### Code - _using sed_
The sed -n '10p' file.txt command prints the 10th line of the file named file.txt. The -n option tells sed not to print anything by default, and the 10p command tells sed to print the 10th line.

```bash
sed -n '10p' file.txt
```

### Code - _using awk_
```bash
# The variable "$0" refers to the entire line that AWK reads in
cat file.txt | awk '{if (NR == 10) print $0;}'
# or shorter
awk '{if (NR == 10) print $0;}' file.txt
# or even shorter
awk 'NR == 10' file.txt
```

#### Question/Answer awk
- [What does it mean when an awk script has code outside curly braces?](https://stackoverflow.com/questions/38596130/what-does-it-mean-when-an-awk-script-has-code-outside-curly-braces)
- Answer: in the answer section.

If you have:

```bash
{ action }
```

...then that action runs on every line. By contrast, if you have:

```bash
# There's no semicolon after condition!!
condition { action }
```

...then that action runs only against lines for which the condition is true.

Finally, if you have only a condition, then the **default action is print**:

```bash
NR % 2 == 0
```
...will thus print every other line.

You can similarly have multiple pairs in a single script:

```bash
condition1 { action1 }
condition2 { action2 }
{ unconditional_action }
```

...and can also have `BEGIN` and `END` blocks, which run at the start and end of execution.

--
- [What does the semicolon represent in an awk action?](https://stackoverflow.com/questions/11078585/what-does-the-semicolon-represent-in-an-awk-action)
- Answer: in the answer section.

In awk, you can write two statements in one line separated by ;(semi-colon)

```bash
{ num_gold++; wt_gold += $2 }
Otherwize, you should put them into separated lines:

{
    num_gold++
    wt_gold += $2
}
```

To print the variables, you just add print before the variables:

```bash
{
    num_gold++
    wt_gold += $2

    print num_gold
    print wt_gold
}
```

As I said, you can put them all in one line:

```bash
{ num_gold++; wt_gold += $2; print num_gold; print wt_gold; }
```
It's too long!

print also accepts multiple arguments, so try

```bash
print num_gold, wt_gold.
```

path: /shell/Tenth Line.md

filename: Tenth Line.md


text:
# Shared data

显然对于不同的concurrency/parallel element/unit，它们的shared data是可能不同的，下面是一些简单的例子:

1、DBMS  table

2、file

3、memory

4、global variable

参见: wikipedia [Reentrancy (computing)](https://en.wikipedia.org/wiki/Reentrancy_(computing))

> Data has a characteristic called [scope](https://en.wikipedia.org/wiki/Scope_and_extent), which describes where in a program the data may be used. Data scope is either [global](https://en.wikipedia.org/wiki/Global_variable) (outside the [scope](https://en.wikipedia.org/wiki/Variable_scope) of any function and with an indefinite extent) or [local](https://en.wikipedia.org/wiki/Local_variables,_recursion_and_reentrancy) (created each time a function is called and destroyed upon exit).
>
> Local data is not shared by any routines, re-entering or not; therefore, it does not affect re-entrance. Global data is defined outside functions and can be accessed by more than one function, either in the form of [global variables](https://en.wikipedia.org/wiki/Global_variable) (data shared between all functions), or as [static variables](https://en.wikipedia.org/wiki/Static_variable) (data shared by all functions of the same name).

5、......

> NOTE: 后续进行补充

repository: dengking/Parallel-computing

repo_name: dengking/Parallel-computing


text:
# Router

## Router Configuration

Reference: [https://router.vuejs.org/](https://router.vuejs.org/)

Configure routers in `src/router.js`

{% code title="src/router.js" %}
```javascript
routes: [
  {
    path: '/',
    redirect: 'dashboard/alpha',
    component: MainLayout,
    meta: {
      authRequired: true,
      hidden: true,
    },
    children: [
      // Dashboards
      {
        path: '/dashboard/alpha',
        meta: {
          title: 'Dashboard Alpha',
        },
        component: () => import('./views/dashboard/alpha'),
      },
      ...
    ],
  },
]
```
{% endcode %}

## History Mode \(removing /\#/ hash from Url\)

{% hint style="info" %}
Don't forget configure rewrites on your server. Read more: [https://router.vuejs.org/guide/essentials/history-mode.html](https://router.vuejs.org/guide/essentials/history-mode.html)
{% endhint %}

Uncomment `mode: 'history'` in `src/router.js`

{% code title="src/router.js" %}
```javascript
const router = new Router({
  base: process.env.BASE_URL,
  // mode: 'history',
  scrollBehavior() {
    return { x: 0, y: 0 }
  },
  ...
}
```
{% endcode %}

## Routes Guard

See `src/router.js` for `router.beforeEach` method. On every route change the app checked authorization and if user is not authorized will redirect him to `/user/login` route.

Details: [https://router.vuejs.org/guide/advanced/navigation-guards.html](https://router.vuejs.org/guide/advanced/navigation-guards.html)

repository: willypelz/sellpixels-docs

repo_name: willypelz/sellpixels-docs


text:
XprojEdit
=========

*xprojedit* allows users working with xcode projects to make changes without
having to open Xcode.  Why would anyone ever want to do that?  Some programmers
would rather use their favorite text editors instead of Xcode.  Having to
constantly move back to Xcode just to add a resource .png file can be a pain.
So if you are one of those, you can use this package to make changes to your
xcode project from either the cli executable or via the python library
included.

The cli executable allows you to:

subcommand | description
----------:|:------------------------------------------------------------------
tree       | show tree structure of the project.
find       | find files or folders matching pattern.
addfolder  | add a folder to a group.
addfiles   | add a file or set of files to a specific group.
rmgrp      | remove a group.
syncgrp    | makes sure the contents of a group match the folder it links to.

xprodedit python library
------------------------
The python library *xprojedit.interface* has corresponding functions for each
subcommand from the executable.  So if you'd like to write plug-ins for your
favorite text editor, you could use the *xprojedit.interface* module.

This makes good use of *mod_pbxproj*.  In fact, for all intents and purposes,
xprodedit would appear to be *just* a wrapper to mod-pbxproj.    But I originally intended *xprojedit* to stand on its
own until I saw the excellent work the community has done on mod-pbxproj and I
didn't want to duplicate efforts.

Install
-------

`$ git clone --recurse-submodules http://github.com/redesigndavid/xprojedit`
`$ cd xprojedit && python setup.py build install`

**NOTE**  This uses a submodule to link to another github repo (hence the
addition of --recurse-submodules in the clone command).  When you run `python
setup.py build install`, it would build and install both xprojedit and
mod-pbxproj.  If you'd rather install the 2 yourself, just make sure you put
both somewhere in your PYTHONPATH before running xprojedit.

Sample Usage
------------

To see a tree listing of your project:
`$ xprojedit tree /path/to/project.pbxproj`

To see only groups withouts files:
`$ xprojedit tree /path/to/project.pbxproj -d`

To see tree listing without indents:
`$ xprojedit tree /path/to/project.pbxproj -i`

To grep/search files and folders:
`$ xprojedit find /path/to/project.pbxproj foo`

To only search a folder:
`$ xprojedit find /path/to/project.pbxproj //Resources foo`

You can also use regex patterns:
`$ xprojedit find /path/to/project.pbxproj //Resources foo.*bar`

You can add a folder to a group.  This command adds a folder named foobar to
Resources.
`$ xprojedit addfolder /path/to/project.pbxproj //Resources /path/to/foobar`

You can add files too:
`$ xprojedit addfiles /path/to/project.pbxproj //Resources /path/to/blah*.png`

You can remove groups:
`$ xprojedit rmgrp /path/to/project.pbxproj //Resources/foobar`

Or just sync the group so it would again contain the files and folders of the
folders of the original folder it was supposed to represent.
`$ xprojedit syncgrp /path/to/project.pbxproj //Resources/foobar`

repository: redesigndavid/xprojedit

repo_name: redesigndavid/xprojedit


text:
---
nav_order: 4
parent: The LibreOffice Panel
grand_parent: Code Howtos
---
# Code reorganization

Why

* Separate backend
* Separate GUI code (dialogs) and logic
* Data is now organized around `Citation`, `CitationGroup` instead of arrays for citation group fields, and arrays of arrays for citation fields.\
  Also take `citationKey` as the central data unit, this is what we start with: unresolved `citationKeys` do not stop processing. Although we cannot sort them by author and year, we can still emit a marker that acts as a placeholder and shows the user the problematic key.

## Result

### Layers

![Layers](layers-v1.svg)

### By directories

* `model`
  * `util` : general utilities
    * (`OOPair`, `OOTuple3`) collect two or three objects without creating a new class
    * `OOResult` : while an Optional.empty can comunicate failure, it cannot provide details.\
      `OOResult` allows an arbitrary error object to be provided in case of failure.
    * `OOVoidResult` : for functions returning no result on success, only diagnostics on failure.
    * `OOListUtil`: some utilities working on List
  * `uno` : helpers for various tasks via UNO.\
    These are conceptually independent of JabRef code and logic.
  * `ootext` : to separate decisions on the format of references and citation marks from the actual insertion into the document, the earlier method [OOUtil.insertOOFormattedTextAtCurrentLocation](https://github.com/JabRef/jabref/blob/475b2989ffa8ec61c3327c62ed8f694149f83220/src/main/java/org/jabref/logic/openoffice/OOUtil.java#L112) was extended to handle new tags that describe actions earlier done in code.
    * This became [OOTextIntoOO.write](https://github.com/antalk2/jabref/blob/122d5133fa6c7b44245c5ba5600d398775718664/src/main/java/org/jabref/model/openoffice/ootext/OOTextIntoOO.java#L149)
      * `(change)` Now all output to the document goes through this, not only those from Layout. This allows the citation markers and `jstyle:Title` to use these tags.
        * This allows some backward-compatible extensions to jstyle.\
          `(change)` [Added](https://github.com/antalk2/jabref/blob/122d5133fa6c7b44245c5ba5600d398775718664/src/main/java/org/jabref/logic/openoffice/style/OOBibStyle.java#L92) some extra keywords, in `{prefix}_MARKUP_BEFORE`, `{prefix}_MARKUP_AFTER` pairs to allow bracketing some parts of citation marks with text and/or open/close tag pairs.
    * [OOFormat](https://github.com/antalk2/jabref/blob/improve-reversibility-rebased-03/src/main/java/org/jabref/model/openoffice/ootext/OOFormat.java) contains helpers to create the appropriate tags
    * [OOText](https://github.com/antalk2/jabref/blob/improve-reversibility-rebased-03/src/main/java/org/jabref/model/openoffice/ootext/OOText.java) formalizes the distinction from `String`. I did not change `String` to `OOText` in old code, (in particular in OOStyle).
  * `rangesort` : ordering objects that have an `XTextRange`, optionally with an extra integer to break ties.
    * `RangeSort.partitionAndSortRanges` : since `XTextRangeCompare` can only compare `XTextRange` values in the same `XText`, we partition them accordingly and only sort within each partiion.
    * `RangeSortable` (interface), `RangeSortEntry` (implements) :\
      When we replace `XTextRange` of citation marks in footnotes with the range of the footnote mark, multiple citation marks may be mapped to the same location. To preserve the order between these, `RangeSortable` allows this order to be indicated by returning appropriate indices from `getIndexInPosition`
    * `RangeSortVisual` : sort in top-to-bottom left-to-right order.\
      Needs a functional `XTextViewCursor`.\
      Works on `RangeSortable` values.
    * `FunctionalTextViewCursor` : helper to get a functional `XTextViewCursor` (cannot always)
    * `RangeOverlapWithin` : check for overlaps within a set of `XTextRange` values. Probably O(n\*log(n)). Used for all-to-all check of protected ranges.
    * `RangeOverlapBetween` : check for overlaps between two sets of `XTextRange` values. Assumes one set is small. O(n\*k). Used for checking if the cursor is in a protected range.
  * `backend` : interfaces to be provided by backends.\
    May change as new backends may need different APIs.
  * `style` : data structures and interfaces used while going from ordered list of citation groups to formatted citation markers and bibliography. Does not communicate with the document. Too long to fit here, starting a new section.

## model/style

At the core,

* we have `Citation` values
  * represented in the document by their `citationKey`
  * each may have a `pageInfo`
* A citation group (`CitationGroup`) has
  * a list of citations (`citationsInStorageOrder`)
  * an identifier `CitationGroupId cgid`
    * this allows to refer to the group
    * also used to associate the group to its citation markers location (outside the style part, in [Backend](https://github.com/antalk2/jabref/blob/fed0952cbdaf7a76bcb09b3db5ac48f34f5ca388/src/main/java/org/jabref/logic/openoffice/backend/Backend52.java#L46))
  * `OODataModel dataModel` is here, in order to handle old (Jabref5.2) structure where pageInfo belonged to CitationGroup not Citation
  * `referenceMarkNameForLinking` is optional: can be used to crosslink to the citation marker from the bibliography.
* `CitationGroups` represents the collection of citation groups.\
  Processing starts with creating a `CitationGroups` instance from the data stored in the document.
* `CitedKey` represents a cited source, with ordered backreferences (using `CitationPath`) to the correponding citations.
* `CitedKeys` is just an order-preserving collection of `CitedKeys` that also supports lookup by `citationKey`. While producing citation markers, we also create a corresponding `CitedKeys` instance, and store it in `CitationGroups.bibliography`. This is already sorted, its entries have `uniqueLetter` or `number` assigned, but not converted to markup yet.

Common processing steps:

* We need `globalOrder` for the citation groups (provided externally) `CitationGroups.setGlobalOrder()`
* We need to look up each citationKey in the bibliography databases:
  * `CitationGroups.lookupCitations` collects the cited keys, looks up each, then distributes the results to the citations. Uses a temporary `CitedKeys` instance, based on unsorted citations and citation groups.
* `CitationGroups.imposeLocalOrder` fills `localOrder` in each `CitationGroup`
* Now we have order of appearance for the citations (`globalOrder` and `localOrder`).\
  We can create a `CitedKeys` instance (`bibliography`) according to this order.
* For citations numbered in order of first appearance we number the sources and distribute the numbers to the corresponding citations.
* For citations numbered in order of bibliography, we sort the bibliography, number, distribute.
* For author-year citations we have to decide on the letters `uniqueLetter` used to distinguish sources. This needs order of first appearance of the sources and recognizing clashing citation markers. This is done in logic, in [`OOProcessAuthorYearMarkers.createUniqueLetters()`](https://github.com/antalk2/jabref/blob/122d5133fa6c7b44245c5ba5600d398775718664/src/main/java/org/jabref/logic/openoffice/style/OOProcessAuthorYearMarkers.java#L49)
* We also mark first appearance of each source ([`setIsFirstAppearanceOfSourceInCitations`](https://github.com/antalk2/jabref/blob/fed0952cbdaf7a76bcb09b3db5ac48f34f5ca388/src/main/java/org/jabref/logic/openoffice/style/OOProcessAuthorYearMarkers.java#L146))

The entry point for this processing is: [`OOProcess.produceCitationMarkers`](https://github.com/antalk2/jabref/blob/fed0952cbdaf7a76bcb09b3db5ac48f34f5ca388/src/main/java/org/jabref/logic/openoffice/style/OOProcess.java#L69).\
It fills

* each `CitationGroup.citationMarker`
* `CitationGroups.bibliography`
  * From bibliography `OOFormatBibliography.formatBibliography()` creates an `OOText` ready to be written to the document.

## logic/style

* `StyleLoader` : not changed (knows about default styles) Used by GUI
* `OOPreFormatter` : LaTeX code to unicode and OOText tags. (not changed)
* `OOBibStyle` : is mostly concerned by loading/parsing jstyle files and presenting its pieces to the rest. Originally it also contains code to format numeric and author-year citation markers.
  * Details of their new implementations are in [`OOBibStyleGetNumCitationMarker`](https://github.com/antalk2/jabref/blob/improve-reversibility-rebased-03/src/main/java/org/jabref/logic/openoffice/style/OOBibStyleGetNumCitationMarker.java) and [`OOBibStyleGetCitationMarker`](https://github.com/antalk2/jabref/blob/improve-reversibility-rebased-03/src/main/java/org/jabref/logic/openoffice/style/OOBibStyleGetCitationMarker.java)
  * The new implementations
    * support pageInfo for each citation
    * support unresolved citations
    * instead of `List<Integer>` and (`List<BibEntry>` plus arrays and database) they expect more self-contained entries `List<CitationMarkerNumericEntry>`, `List<CitationMarkerEntry>`.
    * We have distinct methods for `getNormalizedCitationMarker(CitationMarkerNormEntry)` and `getNumCitationMarkerForBibliography(CitationMarkerNumericBibEntry)`.
    * The corresponding interfaces in model/style:
      * `CitationMarkerNumericEntry`
      * `CitationMarkerEntry`
      * `CitationMarkerNumericBibEntry`
      * `CitationMarkerNormEntry`\
        describe their expected input entries.
* [`OOProcess.produceCitationMarkers`](https://github.com/antalk2/jabref/blob/fed0952cbdaf7a76bcb09b3db5ac48f34f5ca388/src/main/java/org/jabref/logic/openoffice/style/OOProcess.java#L69) is the main entry point for style application. Calls to specific implementations in `OOProcessCitationKeyMarkers`, `OOProcessNumericMarkers` and `OOProcessAuthorYearMarkers` according to jstyle flags.

## logic/backend

Details of encoding and retrieving data stored in a document as well as the citation maker locations. Also contains dataModel-dependent code (which could probably be moved out once the datamodel is settled).

Creating and finding the bibliography (providing a cursor to write at) should be here too.\
These are currently in `UpdateBibliography`

## logic/frontend

* `OOFrontend` : has a `Backend` and `CitationGroups`
  * Its constructor creates a backend, reads data from the document and creates a CitationGroups instance.
  * provides functionality that requires both access to the document and the CitationGroups instance
* `RangeForOverlapCheck` used in `OOFrontend`
* `UpdateBibliography` : Create, find and update the bibliography in the document using output from `produceCitationMarkers()`
* `UpdateCitationMarkers` create `CitationGroup`, update citation markers using output from `produceCitationMarkers()`

## logic/action

GUI-independent part of implementations of GUI actions.

## gui

* `OOError` : common error messages and dialog titles
  * adds `title` to `Jabrefexception`
  * converts from some common exception types using type-specific message
  * contains some dialog messages that do not correspond to exceptions
* `OOBibBase2` : most activity was moved out from here to parts discussed above.
  * connecting / selecting a document moved to `OOBibBaseConnect`
  * the rest connects higher parts of the GUI to actions in logic
    * does argument and precondition checking
    * catches all exceptions
    * shows error and warning dialogs
    * adds `enterUndoContext`, `leaveUndoContext` around action code

repository: JabRef/jabref

branch_name: refs/heads/main

gha_language: Java

repo_name: JabRef/jabref


text:
# Conversion Microservices
For this exercise we will build a variety of conversion servers---programs which take a number with one input unit and output something different, e.g., converting from feet to inches.

**You will do this exercise in groups of 2-3 students.** Each table must have three different groups if possible.

**First, be sure to get the code!** Use these commands:
```
# If you don't already have a copy form Exercise 1:
git clone https://github.com/gwDistSys15/dist-sys-exercises.git

# Or, if you do have an old clone of the repo, then just update it:
cd dist-sys-exercises
git pull origin master
```

**Run your code on Koding.com** so that it will have a public hostname that everyone can connect to.

## Pick a Service. Write a Server.
Each group must pick one of the services from the following list.  No duplicates can be picked until all services have been selected once. Alternatively, you can propose a new conversion, as long as one of its units is already included in the list below.

```
1.  feet <-> inches
2.  inches <-> cm
3.  cm <-> m
4.  kg <-> g
5.  kg <-> pounds
6.  pounds <-> ounces
7.  ounces of bananas <-> dollars
8.  pounds of bananas <-> bananas
9.  bananas <-> length in inches
10. bananas <-> grams of potassium
11. dollars <-> Japanese Yen
```

To be consistent, we will use these abbreviations:

Abbreviation | Unit
------|-----
ft | feet
in | inches
cm | centimeters
m | meters
kg | kilograms
g | grams
lbs | pounds
b | bananas
$ | dollars
y | yen

Your group must write a server that accepts requests to convert between the two units you have selected. It should be able to convert in either direction.

**You may choose to write your server in C, Python, or Java. I suggest Python or Java.** There are example server programs in the `templates/` directory which can send a welcome message to the client and receive an input string. You should copy one of these to make your program.

#### Protocol Specification

Your server program must follow this protocol:
  * Server waits for client connections
  * Client connects to server
  * Server sends a one line message to client saying what the server can do.
    * For example: `Welcome to the Feet (ft) to Inches (in) conversion server!\n`
  * Client sends a request to the server
    * This must be a space separated string: `<input unit> <output unit> <input amount>\n`
    * The string should end with a new line character. The units must be the abbreviations in the table above.
  * Server responds with the conversion result
    * This must be a string and will end with a a new line character, e.g., `"43.2356\n"`
  * The client and server close the socket
  * The server waits for another client to connect

For example the request `"ft in 1.25"` should get the response `"15"`, while `"in ft 30"` should return `"2.5"`.

You should test that your server works using `telnet` as the client.

#### Parsing Requests
You will have to use string parsing functions to extract the different portions of the request.  Here are some tips.

##### C version:
You could use:
```
char * strtok (char *restrict newstring, const char *restrict delimiters)
```

This function returns a piece of `newstring` that has been separated using the delimiter character from `delimiters`. For example:

```
const char s[2] = " "; // space as delimiter
char *token;
/* get the first token */
token = strtok(str, s);
/* walk through other tokens */
while( token != NULL ) {
  printf( " %s\n", token )
  token = strtok(NULL, s);
}
```

Learn more: http://www.gnu.org/software/libc/manual/html_node/Finding-Tokens-in-a-String.html

##### Java version:
You could use the "split" method as below:

```
String[] tokens = str.split("  ");
for(String s:tokens){
       System.out.println(s);
   }
```

Learn more: http://javadevnotes.com/java-string-split-tutorial-and-examples

##### Python version:
You could use split function as below:
```
mylist = inputString.split(" ")
for item in mylist:
   print item
```
Learn more: http://www.tutorialspoint.com/python/string_split.htm

**You will also need to convert from strings to floating point numbers.  You can use any websites you'd like to learn how to do that.**

## Answering Questions with Multiple Services
Using these services, we will try to answer questions like:
  - How many kilograms is 45.6 pounds?
  - If I lay 150 bananas end to end, how long will they be in feet?
  - How much would it cost in Japanese Yen for enough bananas to get 43 grams of potassium?
  - If I buy $56.34 worth of bananas and lay them end to end, how long will they be in centimeters?

To do this, you will have to make a server that is capable of talking with other servers! **Rather than edit your existing server, make a new one which can talk to it and another server.**  Coordinate with other students at your table to find IPs and service types you can use.

What is the most interesting question you can answer using the servers written by groups at your table?  What if you talk with students from other tables?

repository: onorzq/dist-sys-exercises

repo_name: onorzq/dist-sys-exercises


text:
# DEPRECATED

With the merge of https://github.com/kubevirt/kubevirt/pull/4703 this
repository is no longer needed in `kubevirt/kubevirt`.

The repository may get some sporadic fixes for kubevirt/kubevirt releses prior
to `v0.37.0` until they are EOL.

# Containerized libvirtd and QEMU

This is a simple container wrapping libvirtd.

## Purpose

Instead of delivering libvirtd in a package, libvirtd is
now delivered in a container. This container is used as
the base container image for `virt-launcher` to run
as the entrypoint, it is not intended to be run standalone.

## Build types

The specifics of the build process vary based on the type of build.

### Official builds

These happen on Travis CI, as three separate steps:

* first the environment is set up using the `hack/prepare.sh` script;

* then several single-architecture containers are built and tested,
  using `qemu-user` for cross-architecture support, as part of the
  `hack/build.sh` script;

* finally, a multi-architecture container is assembled and pushed to
  Docker Hub using the `hack/deploy.sh` script.

The entire process is described in `.travis.yml`, and no human
intervention is necessary.

### Local builds

These builds are mostly useful for maintainers.

It is expected that you have `docker buildx` set up and configured to
perform cross-architecture builds, as well as a local Docker registry
running on your machine.

To create a local build, use something like

```bash
$ IMAGE_NAME=localhost:5000/my-libvirt ./hack/local-build.sh
```

### Simple builds

These builds are perfect for quick testing: a single-architecture
container is built, so there is no additional setup required.

To create a simple build, use something like

```bash
$ IMAGE_NAME=my-libvirt ./hack/simple-build.sh
```

## Build configuration

The default configuration, which is used for official builds, is
stored in `hack/config`. See the file for information on how to
override some of the settings for a specific build.

repository: kubevirt/libvirt

gha_language: Shell

repo_name: kubevirt/libvirt


text:
# DIY Wi-Fi LEDStrip Controller

Project status: Work in progress.

DIY Wi-Fi LED strip controller based on the ESP32 chip and MicroPython. Contains step-by-step build guide with links to parts. The controller can be controlled via raw sockets or with an android app.

### Parts
- 1x NodeMCU ESP32 : [eBay LINK 1pc](https://www.ebay.com/itm/Espressif-ESP32-WLAN-Dev-Kit-Board-Development-Bluetooth-Wifi-v1-WROOM32-NodeMCU/253059783728?hash=item3aeb89dc30:g:5-8AAOSwAThb3MaZ)
- 3x 1KOhm resistor: [eBay LINK 100pc](https://www.ebay.com/itm/100-pcs-1-4W-0-25W-1-Metal-Film-Resistor-1K-ohm-1Kohm/282033455842?_trksid=p2485497.m4902.l9144)
- 1x 12v Female DC Power Socket: [EBAY LINK 10pc](https://www.ebay.com/itm/10Pcs-5-5-x-2-1mm-12-V-DC-Power-Supply-Jack-Socket-Female-Panel-Mount-Connector/143449192665?_trksid=p2485497.m4902.l9144)
- 1x Female strip connector: [EBAY LINK 5pc](https://www.ebay.com/itm/Durable-4Pin-Male-Female-Connector-Wire-Cable-for-3528-5050-SMD-LED-Strip-Light/352235582745?epid=1155449649&hash=item5202e07519:g:koEAAOSw8b1aN2vm)
- 1x RGB LED strip: [eBay LINK 1pc](https://www.ebay.com/itm/184203854470?ViewItem=&item=184203854470)
- 3x Tip31c transistor: [eBay LINK 10pc](https://www.ebay.com/itm/10-x-TIP31C-TIP31-NPN-Transistor-3A-100V-TO-220-FSC/270984720497?hash=item3f17f2b071:g:8hUAAOxyepRRrfsF)
- 1x 12v Power Supply Adapter (2A for a 5M long strip): [eBay LINK 1pc](https://www.ebay.com/itm/AC-TO-DC-5V-12V-24V-1A-2A-3A-5A-10A-0-5A-Power-Supply-Adapter-LED-Strip-Light/254344416209?_trksid=p2485497.m4902.l9144)
- 1x 12v to 5v Converter: [eBay LINK 1pc](https://www.ebay.com/itm/DC-DC-12V-to-5V-6V-9V-2-3A-15W-Converter-Step-Down-2A-3A-15W-Power-Supply-Module/401327863545?_trksid=p2485497.m4902.l9144)
- 1x PCB. Upload the attached Gerber files to jlcpcb.com. (Minimum amount is 5pc)
- 8x M2.5-3.5 bolts&nuts. 20-30 mm long [eBay LINK](https://www.ebay.com/itm/M2-M2-5-M3-304-Stainless-Steel-Allen-Hex-Socket-Countersunk-Head-Screws-Bolts/282935136527?hash=item41e03f910f:m:mKxIf5Qmt5Zi86DIH4-mAoQ)
- 2x Simple 5 cm long wire

### Tools
- Soldering iron
- small pliers (or tiny hands)
- 3d printer (optional, you can make everything except for the case.)
- Windows or Linux PC.

# Makers guide
First order all the necessary parts and make sure you have all the required tools.
While waiting for the parts to arrive you can already install a version of [python](https://www.python.org/) on your PC.
Make sure you install version 3.7 or higher.
After installing python you can connect your esp32 board to your PC using a micro USB cable,
install [esptool](https://pypi.org/project/esptool/) and flash your esp32 with the MicroPython firmware. You can find a great guide for all this
over [here](https://docs.micropython.org/en/latest/esp8266/tutorial/intro.html). **Make sure to hold the "Boot" button on the board while writing and erasing flash or it won't work.**

The last thing we should do before we start soldering is put
the [attached scripts](https://github.com/Ruud14/DIY-Wifi-LEDStrip-Controller/tree/master/to_ESP32) on the board.
You can do this with a tool called [ampy](https://learn.adafruit.com/micropython-basics-load-files-and-run-code/install-ampy) .
Simply install ampy by running 'pip3 install adafruit-ampy' in your terminal. After that you can put all the scripts on your board by running:
'ampy --port YOUR_PORT put boot.py',
'ampy --port YOUR_PORT put main.py',
'ampy --port YOUR_PORT put objects.py',

After this you can disconnect your esp32 from your PC and start soldering.
I tried to mark everything on the PCB as good as possible, but you can look at the [pictures](https://github.com/Ruud14/DIY-Wifi-LEDStrip-Controller/tree/master/pictures) if it isn't clear enough.
**One thing you really need to look out for is that the wires of the female strip connector aren't in the correct order.
You need to put the red wire in the hole that says 'R', the green one in the hole that says 'G' and the blue one in the hole that says 'B'.**
**Another thing to note is that the shortest end of the female dc power socket should be connected to the positive end of the board**

*This part is for the ones that are printing the case.
You can download the [attached .stl files](https://github.com/Ruud14/DIY-Wifi-LEDStrip-Controller/tree/master/3d%20models)
convert them to g-code and print them. Make sure you enable support material for the bottom part.*

After everything is done you should check that no soldered connections are touching each other and connect your soldered PCB to power.
Just to check you can scan for nearby Wi-Fi networks on your phone and you should see a network called "LedStrip Setup" if everything is alright.
Now your very own controller is done and you can install the app to control the strip [here](https://github.com/Ruud14/Wifi-LEDStrip-Controller-App).
You can also control the strip by sending raw socket commands in the following format:

(1024,0,0);Fade(0.2);(0,0,0);Wait(0.2)

The string should always start with a RGB color '(r,g,b)'
where the values of r, g and b must be between 0 and 1024.
After a color comes a transition. The two options are 'Fade(x)' and 'Wait(x)' .
A color can only be followed up by a transition and a transition can only be followed up by a color.
Colors and transitions must be separated by a ';'. The string must always end with a transition.

**Just to make sure that the ip of your strip controller doesn't change when the router resets, Reserve the ip addresses of the strip controller in the settings of your router.** You can find the ip of your controller in [The android app](https://github.com/Ruud14/Wifi-LEDStrip-Controller-App) after you added the strip.

![fully_assembled](https://github.com/Ruud14/DIY-Wifi-LEDStrip-Controller/blob/master/pictures/fully_assembled.jpg)
![inside_case](https://github.com/Ruud14/DIY-Wifi-LEDStrip-Controller/blob/master/pictures/inside_case.jpg)
![soldered_pcb1](https://github.com/Ruud14/DIY-Wifi-LEDStrip-Controller/blob/master/pictures/soldered_pcb1.jpg)

### Additional info.
**What I learned:**
- Working access point networks.
- Working with the esp32 (Had used a esp8266 before).
- Designing a PCB.

Licensed under the [MIT License](https://github.com/Ruud14/DIY-Wifi-LEDStrip-Controller/blob/master/LICENSE)

gha_language: Python


text:
# Changelog

## 1.0.0

  * Initial release

  Differences between 1.0.0 and BETA:

  - Naming changes
    - Packagist package name: `klaviyo/sdk-beta` → `klaviyo/api`
    - Namespace: `KlaviyoBeta` → `KlaviyoAPI`
    - client name: `Client` → `KlaviyoAPI`
    - Client variable name in readme examples: `$client` → `$klaviyo`
    - Some functions have changed name
  - Parameter ordering: The order of params has changed; you will need to update these for your existing implementation to work
  - New resources and endpoints: see [API Changelog](https://developers.klaviyo.com/en/docs/changelog_) for full details


text:
---
page_type: sample
languages:
- csharp
products:
- azure
- azure-search
- azure-cognitive-services
name: Text Analytics for Health Custom Skill for Cognitive Search
description: This custom skill utilizes the Text Analytics for Health API to identify healthcare entities and relations.
azureDeploy: https://raw.githubusercontent.com/Azure-Samples/azure-search-power-skills/main/Text/TextAnalyticsForHealth/azuredeploy.json
---

# TextAnalyticsForHealth

This custom skill utilizes the Text Analytics for Health API to identify healthcare entities and relations. You can learn more about how the Text Analytics for Health API works by reading their [docs](https://docs.microsoft.com/en-us/azure/cognitive-services/text-analytics/).

## Requirements

In addition to the common requirements described in [the root `README.md` file](../../README.md), this function requires access to a [Text Analytics](https://docs.microsoft.com/en-us/azure/cognitive-services/text-analytics/) service.
If deploying through the ARM Template below, a Text Analytics Account will be created for you.

## Settings

This function requires `TEXT_ANALYTICS_API_ENDPOINT` and `TEXT_ANALYTICS_API_KEY` to be set in the settings.This is set automatically when deploying from the ARM Template.
If running locally, this can be set in your project's debug environment variables (go to project properties, in the debug tab). This ensures your key won't be accidentally checked in with your code.
If running in an Azure function, this can be set in the application settings.

## Deployment

[![Deploy to Azure](https://azuredeploy.net/deploybutton.svg)](https://portal.azure.com/#create/Microsoft.Template/uri/https%3A%2F%2Fraw.githubusercontent.com%2FAzure-Samples%2Fazure-search-power-skills%2Fmain%2FText%2FTextAnalyticsForHealth%2Fazuredeploy.json)

## Sample Input:

```json
{
    "values": [
        {
            "recordId": "foobar2",
            "data":
            {
                "text": "100mg Ibuprofen"
            }
        },
        {
            "recordId": "foo1",
            "data":
            {
                "text": "200mg Tylenol",
                "languageCode": "en"
            }
        }
    ]
}
```

## Sample Output:

```json
{
    "values": [
        {
            "recordId": "foobar2",
            "data": {
                "status": "succeeded",
                "entities": [
                    {
                        "text": "100mg",
                        "category": "Dosage",
                        "subCategory": null,
                        "confidenceScore": 1.0,
                        "offset": 0,
                        "length": 5,
                        "dataSources": [],
                        "assertion": null,
                        "normalizedText": null
                    },
                    {
                        "text": "Ibuprofen",
                        "category": "MedicationName",
                        "subCategory": null,
                        "confidenceScore": 1.0,
                        "offset": 6,
                        "length": 9,
                        "dataSources": [],
                        "assertion": null,
                        "normalizedText": null
                    }
                ],
                "relations": [
                    {
                        "relationType": {},
                        "roles": [
                            {
                                "entity": {
                                    "text": "100mg",
                                    "category": "Dosage",
                                    "subCategory": null,
                                    "confidenceScore": 1.0,
                                    "offset": 0,
                                    "length": 5,
                                    "dataSources": [],
                                    "assertion": null,
                                    "normalizedText": null
                                },
                                "name": "Dosage"
                            },
                            {
                                "entity": {
                                    "text": "Ibuprofen",
                                    "category": "MedicationName",
                                    "subCategory": null,
                                    "confidenceScore": 1.0,
                                    "offset": 6,
                                    "length": 9,
                                    "dataSources": [],
                                    "assertion": null,
                                    "normalizedText": null
                                },
                                "name": "Medication"
                            }
                        ]
                    }
                ]
            },
            "warnings": [],
            "errors": []
        },
        {...}
    ]
}
```

## Sample Skillset Integration

In order to use this skill in a cognitive search pipeline, you'll need to add a skill definition to your skillset. **If you deploy using the ARM template you can copy the URI from the output of the template.**
The skill also accepts options which can be sent as headers in the request.

| Header Name | Description | Default |
| ----------- | ----------- | ------- |
| `timeout` | Allows you to set a timeout (in seconds) which will cause the skill to return early, so it doesn't timeout in the Cognitive Search Pipeline. | `230` |
| `defaultLanguageCode` | Allows you to set a default language across all documents in case a language is not provided in the input | `en` |

**It is important to note** the difference between the timeout option in the header, and the timeout option/behavior when defining a skillset. If a request to a web skill takes longer than the timeout defined in the skillset, it will simply drop the request and move on. With the timeout header option, it allows users to define how long the function should wait before it returns the results it has so far, and returns errors for the documents it has not yet gotten to or not yet received results on.

Here's a sample skill definition for this example (inputs and outputs should be updated to reflect your particular scenario and skillset environment):

```json
{
<EMAIL_ADDRESS>"#Microsoft.Skills.Custom.WebApiSkill",
    "description": "Our new Text Analytics For Health Custom Skill",
    "context": "/document",
    "uri": "[AzureFunctionEndpointUrl]/api/TextAnalyticsForHealth?code=[AzureFunctionDefaultHostKey]",
    "batchSize": 1,
    "timeout" : "PT3M50S",
    "inputs": [
        {
            "name": "text",
            "source": "/document/content",
            "sourceContext": null
        }
    ],
    "outputs": [
        {
            "name": "entities",
            "targetName": "entities"
        },
        {
            "name": "relations",
            "targetName": "relations"
        },
    ],
    "httpHeaders": {
        "timeout" : "220",
        "defaultLanguageCode" : "en"
    }
}
```

repository: Azure-Samples/azure-search-power-skills

gha_language: C#

repo_name: Azure-Samples/azure-search-power-skills


text:
Specifies the text to output to the when a custom build command or rule is executed.

```lua
buildmessage ("message")
```

### Parameters ###

`message` is the text to write to standard output.

### Applies To ###

Project configurations and rules.

### Availability ###

Premake 5.0 or later.

### See Also ###

* [Custom Build Commands](Custom-Build-Commands.md)
* [Custom Rules](Custom-Rules.md)
* [buildcommands](buildcommands.md)

repository: premake/premake-core

gha_language: C

repo_name: premake/premake-core


text:
Tape by Square, Inc.
====================

Tape is a collection of queue-related classes for Android and Java.

`QueueFile` is a lightning-fast, transactional, file-based FIFO. Addition and
removal from an instance is an O(1) operation and is atomic. Writes are
synchronous; data will be written to disk before an operation returns. The
underlying file is structured to survive process and even system crashes and if
an I/O exception is thrown during a mutating change, the change is aborted.

An `ObjectQueue` represents an ordering of arbitrary objects which can be backed
either by the filesystem (via `QueueFile`) or in memory only.

`TaskQueue` is a special object queue which holds `Task`s, objects which have a
notion of being executed. Instances are managed by an external executor which
prepares and executes enqueued tasks.

*Some examples are available on [the website][1].*

Changes over original:

1. ThreadSafe.
2. Reactive API.

*Example with observables*

```java
        File file = new File("Queuefile");
        ObjectQueue.Converter<String> queueObjectConverter = new ObjectQueue.Converter<String>() {
            @Override
            public String from(byte[] bytes) throws IOException {
                return new String(bytes);
            }

            @Override
            public void toStream(String o, OutputStream bytes) throws IOException {
                bytes.write(o.getBytes());
            }
        };

        ObservableQueue<String> objectObservableQueue = ObservableQueue.createPersistedObservableQueue(file, queueObjectConverter);

        objectObservableQueue
                .add("abc")
                .observeOn(Schedulers.immediate())
                .subscribe(new Action1<Boolean>() {
                    @Override
                    public void call(Boolean aBoolean) {
                        // Persisted successful
                        System.out.println("aBoolean = [" + aBoolean + "]");
                    }
                }, new Action1<Throwable>() {
                    @Override
                    public void call(Throwable throwable) {
                        if (throwable instanceof IOException) {
                            // do something
                            System.out.println("throwable = [" + throwable + "]");
                        } else {
                            // do something else.
                        }
                    }
                });
        objectObservableQueue
                .size()
                .observeOn(Schedulers.immediate()).subscribe(new Subscriber<Integer>() {
            @Override
            public void onCompleted() {

            }

            @Override
            public void onError(Throwable e) {

            }

            @Override
            public void onNext(Integer integer) {
                // Persisted successful
                System.out.println("integer = [" + integer + "]");
            }
        });
        objectObservableQueue.peek().observeOn(Schedulers.immediate()).subscribe(new Subscriber<String>() {
            @Override
            public void onCompleted() {

            }

            @Override
            public void onError(Throwable e) {

            }

            @Override
            public void onNext(String string) {
                System.out.println("string = [" + string + "]");
            }
        });
        objectObservableQueue.close().observeOn(Schedulers.immediate()).subscribe(new Subscriber<Boolean>() {
            @Override
            public void onCompleted() {

            }

            @Override
            public void onError(Throwable e) {

            }

            @Override
            public void onNext(Boolean bBoolean) {
                System.out.println("bBoolean = [" + bBoolean + "]");
            }
        });
```

Download
--------

Download [the latest JAR][2] or grab via Maven:
```xml
<dependency>
  <groupId>com.squareup</groupId>
  <artifactId>tape</artifactId>
  <version>1.2.3</version>
</dependency>
```
or Gradle:
```groovy
compile 'com.squareup:tape:1.2.3'
```

Snapshots of the development version are available in [Sonatype's `snapshots` repository][snap].

License
-------

    Copyright 2012 Square, Inc.

    Licensed under the Apache License, Version 2.0 (the "License");
    you may not use this file except in compliance with the License.
    You may obtain a copy of the License at

       http://www.apache.org/licenses/LICENSE-2.0

    Unless required by applicable law or agreed to in writing, software
    distributed under the License is distributed on an "AS IS" BASIS,
    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    See the License for the specific language governing permissions and
    limitations under the License.

 [1]: http://square.github.com/tape/
 [2]: https://search.maven.org/remote_content?g=com.squareup&a=tape&v=LATEST
 [snap]: https://oss.sonatype.org/content/repositories/snapshots/

repository: bangarharshit/tape

repo_name: bangarharshit/tape


text:
# Microsoft Azure IoTCentral SDK for Node.js

[![Join the chat at https://gitter.im/iotdisc/community](https://badges.gitter.im/iotdisc.svg)](https://gitter.im/iotdisc/community?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
[![Licensed under the MIT License](https://img.shields.io/badge/License-MIT-blue.svg)](https://github.com/lucadruda/iotc-nodejs-device-client/blob/master/LICENSE)

## Prerequisites
+ Node.js version 8.x or higher - https://nodejs.org

## Installing `azure-iotcentral-device-client` and types

```
npm install azure-iotcentral-device-client
```

## Samples

A couple of samples in Javascripts can be found [here](https://github.com/lucadruda/iotc-samples)

When connecting a device to an IoT Central application an IoTCClient is initialized.
SDK supports X509 and SymmetricKey authentication;

#### X509
```
const iotCentral = require('azure-iotcentral-device-client');

const scopeId = '';
const deviceId = '';
const passphrase = ''; //optional
const cert = {
    cert: "public cert"
    key: "private key",
    passphrase: "passphrase"
}

const iotc = new iotCentral.IoTCClient(deviceId, scopeId, 'X509_CERT', cert);
```

#### SAS
```
const iotCentral = require('azure-iotcentral-device-client');

const scopeId = 'scopeID';
const deviceId = 'deviceID';
const sasKey = 'masterKey';

const iotc = new iotCentral.IoTCClient(deviceId, scopeId, 'symm_key', sasKey);
```

### Connect
Using callback
```
iotc.connect(callback)
```
Using promises
```
iotc.connect().then(()=>{
    console.log('Connected");
})
```
After successfull connection, IOTC context is available for further commands.

All the callbacks are optional parameters and are triggered when message has reached the ingestion engine.

### Send telemetry

Send telemetry every 3 seconds
```
setInterval(() => {
            iotc.sendTelemetry({
                field1: value1,
                field2: value2,
                field3: value3
            }, timestamp, sendCallback)
```
An optional timestamp field can be included in the send methods, to specify the UTC date and time of the message. This field must be in ISO format (e.g., YYYY-MM-DDTHH:mm:ss.sssZ). If timestamp is not provided, the current date and time will be used.

### Send state update
```
iotc.sendState({fieldName:'fieldValue'}, timestamp, sendCallback);
```
### Send event
```
iotc.sendEvent(event, timestamp, sendCallback);
```
### Send property update
```
iotc.sendProperty({fieldName:'fieldValue'}, sendCallback);
```
### Listen to settings update
```
iotc.on('SettingsUpdate', callback);
```
To provide setting sync aknowledgement, the client can send back a property with the same name of the setting and a particular value object.
```
iotc.on('SettingsUpdated', (val) => {
            Object.keys(val).forEach(setting => {
                iotc.sendProperty({
                    [setting]: {
                        value: val[setting].value,
                        status: 'completed',
                        desiredVersion: val.$version,
                        message: 'whatever'
                    }
                });
            });
        });
```

### Listen to commands
```
iotc.on('Command',callback);
```
To provide feedbacks for the command like execution result or progress, the client can send back a property with the same name of the executing command.
```
iotc.on('Command', (cmd) => {
    // send execution start feedback
    iotc.sendProperty({
                [cmd.commandName]: {
                    value: 'Command execution started at ' + new Date().toISOString(),
                    requestId:cmd.requestId
                    }
            }, sendCallback);
        });
```

## One-touch device provisioning and approval
A device can send custom data during provision process: if a device is aware of its IoT Central template Id, then it can be automatically provisioned.

### How to set IoTC template ID in your device
Template Id can be found in the device explorer page of IoTCentral
![Img](assets/modelId.jpg)

Then call this method before connect():

```
iotc.setModelId('<modelId>');
```

### Manual approval (default)
By default device auto-approval in IoT Central is disabled, which means that administrator needs to approve the device registration to complete the provisioning process.
This can be done from explorer page after selecting the device
![Img](assets/manual_approval.jpg)

### Automatic approval
To change default behavior, administrator can enable device auto-approval from Device Connection page under the Administration section.
With automatic approval a device can be provisioned without any manual action and can start sending/receiving data after status changes to "Provisioned"

![Img](assets/auto_approval.jpg)

## Generate x509 certificates
IoT Central SDK comes with a tool to generate self-signed x509 certificates to be used when testing device connection.
If you want to generate certificates for 6 devices and also validate the authority you can run something like this:
```
const IoTCentral = require('azure-iotcentral');
const readline = require('readline');

const certificateGenerator = new IoTCentral.CertificateGenerator(6);
certificateGenerator.init()
    .then(() => {
        console.log('Generating root certificate');
        certificateGenerator.generateRoot.bind(certificateGenerator)()
            .then(() => {
                console.log('Generating device certificates');
                certificateGenerator.createDevices.bind(certificateGenerator)()
                    .then(() => {
                        const rl = readline.createInterface({
                            input: process.stdin,
                            output: process.stdout
                        });
                        rl.question('Insert validation code: ', async (answer) => {
                            const validationCert = await certificateGenerator.validate.bind(certificateGenerator)(answer);
                            console.log(`Validation certificate create at '${validationCert}'`);
                            rl.close()
                        });
                    })
            })
    });
```
This example wait for a validation code which is provided by IoTCentral in the device configuration page when uploading primary or secondary root certificate.
Resulting device certificates can be used in connection example above.

repository: elvinm/iotc-nodejs-device-client

repo_name: elvinm/iotc-nodejs-device-client


text:
# sensu-client

Install/configure Sensu client

Role Variables
--------------

See [defaults/main.yml](defaults/main.yml) for a list and description of
variables used in this role.

Example Playbook
----------------

TODO: Add example playbook(s).

```yaml
- hosts: sensu_servers
  vars:
    sensu_server_enabled: yes
    sensu_api_enabled: yes
  roles:
     - role: rabbitmq
     - role: redis
     - role: sensu
```

```yaml
- hosts: webservers
  roles:
    - role: sensu
```

### SSL Configuration

#### Generating SSL Keys/Certs
A helper play is included to generate SSL certs/keys and present them as yaml
to be used with this role. It is of course recommended the generated content is
saved using Ansible Vault.

```
ansible-playbook tasks/ssl_generate.yml
```

This will download the sensu ssl tool, generate the ssl content, then save them
to a yaml file. By default the content is saved to `/tmp` but it can be adjusted.
See `tasks/ssl_generate.yml` for details.

repository: bdclark/ansible-sensu

repo_name: bdclark/ansible-sensu


text:
mbpm2git
===
mbpm2git is a command line tool that converts *.xep* or *.xel* file into text file to be used with git or any other version control system.

Overview
---
Metastorm BPM 7 procedures and libraries files are stored in zip format files with .xep or .xel extension.
This format is unsuitable to track changes or to be used with a version control system like git.
mbpm2git automates the workflow and extracts the content in text and xml files ready to be committed to git.

Install
---
- Copy the bin directory in *Programs Files* folder renaming it mbpm2git (`C:\Program Files\mbpm2git`)
- Add the folder to the system's path with **setx** command (`setx /m path "%path%;C:\Program Files\mbpm2git"`)

Use
---
**`mbpm2git.exe -i`***`xep/xel-file`***`-o`***`output-directory`***`[-f] [-c]`**

Options:
```
  -i, --input        Required. Input file to read
  -o, --output       Required. Output path to write
  -f, --formatxml    Format xml file
  -c, --copy         Copy xep or xel file
  --help             Display this help screen.
```

License
---
The license of the project is the [MIT](LICENSE).


text:
---
title: Wakoopa officially shutdown – grab your data now
author: Sathyajith Bhat
type: post
date: 2012-07-05T17:19:00+00:00
url: /2012/07/05/wakoopa-officially-shutdown-grab-your-data-now/

categories:
  - General

tags:
  - linux

---
About 2 weeks ago, Wakoopa announced that they will be shutting down their social network soon & focusing on "Corporate Research".

Unfortunately that day is here. Just received an email stating that as of today, you can grab an export of your data.

This is what they have to say about the export

>

>   The export is a CSV file containing the following columns: application name, subcategory, category, the number of seconds you've used the application in the hour, the hour you've used the application in, the date of the usage, the operating system and your user id.
>

>
>

>   For instance, say you have a line like this:Skype Messengers & Chat Internet 10 31/05/2012 20:00:00 win 12345
>

>
>

>   This would mean: the user with ID=12345 used the Windows version Skype (which is an Internet > Messengers & Chat software) for 10 seconds on 31st of May 2012 between 20:00 - 21:00.
>

Too bad Wakoopa's no longer going to be around. Wakoopa would be the first software I'd install - even before installing the drivers. There was something analysing the data about what software you use for how long, and which software did I use the most in the background. Now, I'm not really sure what to do with the data. I don't think Rescue Time supports importing Wakoopa data - it'd be sweet if they did. Maybe see if I can stuff if into ProcrastiTracker?

gha_language: HTML


text:
# Sample Transformers

AIStore hosts a variety of sample transformers in the form of Docker images to be used with ETL workflows on AIStore via the [`init spec`](https://github.com/NVIDIA/aistore/blob/master/docs/etl.md#init-spec-request) functionality.

| Transformer | Language | Communication Mechanisms | Description |
| ---------- | -------- | ------------------------ | ----------- |
| [`echo`](https://github.com/NVIDIA/ais-etl/tree/master/transformers/echo) | `python:3.11` | `hpull`, `hpush`, `hrev` | Returns the original data, with an `MD5` sum in the response headers. |
| [`go_echo`](https://github.com/NVIDIA/ais-etl/tree/master/transformers/go_echo) | `golang:1.20` | `hpull`, `hpush`, `hrev` | Returns the original data, with an `MD5` sum in the response headers. |
| [`hello_world`](https://github.com/NVIDIA/ais-etl/tree/master/transformers/hello_world) | `python:3.11` | `hpull`, `hpush`, `hrev` | Returns `Hello World!` string on any request. |
| [`md5`](https://github.com/NVIDIA/ais-etl/tree/master/transformers/md5) | `python:3.11` | `hpull`, `hpush`, `hrev` | Returns the `MD5` sum of the original data as the response. |
| [`tar2tf`](https://github.com/NVIDIA/ais-etl/tree/master/transformers/tar2tf) | `golang:1.20` | `hrev` | Returns the transformed TensorFlow compatible data for the input `TAR` files. |
| [`compress`](https://github.com/NVIDIA/ais-etl/tree/master/transformers/compress) | `python:3.11` | `hpull`, `hpush`, `hrev` | Returns the compressed or decompressed data using `gzip` or `bz2`. |
| [`ffmpeg`](https://github.com/NVIDIA/ais-etl/tree/master/transformers/ffmpeg) | `python:3.11` | `hpull`, `hpush`, `hrev` | Returns the `FFMPEG` decoded data. |
| [`keras`](https://github.com/NVIDIA/ais-etl/tree/master/transformers/keras_preprocess) | `python:slim` | `hpull`, `hpush`, `hrev` | Returns the transformed images using `Keras` pre-processing. |
| [`torchvision`](https://github.com/NVIDIA/ais-etl/tree/master/transformers/torchvision_preprocess) | `python:slim` | `hpull`, `hpush`, `hrev` | Returns the transformed images using `Torchvision` pre-processing. |

## General Usage

The following sections demonstrate initializing ETLs on AIStore using the provided sample transformers.

> For detailed usage information regarding the `Tar2TF`, `Compress`, `FFMPEG`, `Keras`, `Torchvision` transformers and their optional parameters, please refer to the `README` documents located in their respective sub-directories.

#### Pre-Requisites

[ETLs](https://github.com/NVIDIA/aistore/blob/master/docs/etl.md) on AIStore requires the installation and use of Kubernetes.

> For more information on AIStore Kubernetes deployment options, refer [here](https://github.com/NVIDIA/aistore/blob/master/docs/etl.md#kubernetes-deployment).

### Usage w/ AIStore CLI

The basic procedure is as follows:

1. Change directory into sub-directory of desired sample transformer.
2. Export communication mechanism (and optional arguments if any) as environment variables.
3. Substitute environment variables into the provided `YAML` specification file (`pod.yaml`).
4. Initialize ETL w/ AIStore CLI providing path to the generated `YAML` specification file.

The following demonstrates basic usage:

```bash
# Change Directory (to Desired Sample Transformer)
cd ais-etl/transformers/md5

# Export Environment Variables for Communication Mechanism (& Any Additional Arguments)
export COMMUNICATION_TYPE = "hpull://"

# Subsitute Environment Variables in YAML Specificiation
eval "echo \"$(cat pod.yaml)\"" > md5_pod_config.yaml

# Initialize ETL on AIStore via CLI
ais etl init spec --name md5-etl --from-file "./md5_pod_config.yaml"
```

### Usage w/ AIStore Python SDK

The `YAML` specification files for the sample transformers are provided as [templates](https://github.com/NVIDIA/aistore/blob/master/python/aistore/sdk/etl_templates.py) in the [Python SDK](https://github.com/NVIDIA/aistore/blob/master/python/aistore/sdk/README.md).

The basic procedure is as follows:

1. Import desired sample transformer's YAML specification template.
2. Format communication mechanism (and optional arguments if any) into template.
3. Initialize ETL w/ AIStore SDK providing the formatted template.

The following demonstrates basic usage:

```python
from aistore.sdk.client import Client
from aistore.sdk.etl_templates import ECHO
from aistore.sdk.etl_const import ETL_COMM_HPULL

AIS_ENDPOINT = os.environ.get("AIS_ENDPOINT")
client = Client(AIS_ENDPOINT)

echo_etl_template = ECHO.format(communication_type=ETL_COMM_HPULL)

client.etl("echo-etl").init_spec(template=echo_etl_template, communication_type=ETL_COMM_HPULL)
```

## Contribution

The maintenance of the sample transformers on [DockerHub](https://hub.docker.com/u/aistorage) is managed by the [`ais-etl`](https://github.com/NVIDIA/ais-etl) GitHub repository.

To contribute, push any changes to sample transformers to the GitHub repository. The existing GitHub workflows will build and push the updated sample transformers to the [DockerHub](https://hub.docker.com/u/aistorage) repostiory.

> For more information, refer to the GitHub workflow files [here](https://github.com/NVIDIA/ais-etl/tree/master/.github/workflows).

## References

- [Python SDK](https://github.com/NVIDIA/aistore/blob/master/python/aistore/sdk/README.md)
- [AIStore CLI](https://github.com/NVIDIA/aistore/blob/master/docs/cli.md)
- [AIS-ETL](https://github.com/NVIDIA/aistore/blob/master/docs/etl.md)

repository: NVIDIA/ais-etl

repo_name: NVIDIA/ais-etl


text:
##Description
This Repo contains PowerShell and Desired State Configuration examples used in the following presentations at the PowerShell Summit Europe 2015 in Stockholm Sweden:

##Session (YouTube Videos)
- [Enabling DevOPs using PowerShell 5.0](https://www.youtube.com/watch?v=90zjUk0pJ1w)
- [What's Up with DSC Pull Server](https://www.youtube.com/watch?v=y3-_XBQTpS8)
- [What's new in DSC](https://www.youtube.com/watch?v=0Jc4qNZabU8)

##Repo Contents
The contents for each session are stored in an individual folder ... for the most part. Since we did not have time to finish some of the content in some sessions, we covered the content in a later session.

- \Debugging\\* contains content from the _Enabling DevOps using PowerShell 5.0_ session. Also covered in _What's New in DSC_ session.
- \DevOps\\* contains content from _Enabling DevOps using PowerShell 5.0_ session.
- \PullServer\\* contains content from _What's Up with DSC Pull Server_ session.

###File Details
| Path           |  File Name   | Description          |
| ------------- | ------------ | -------------------- |
| Assets        | site.zip     | Pull Server ASP.Net WebApp content.|
| Debugging     | 00 - debugging flow.ps1 | Script used to demonstrate new debugging functionality. |
| Debugging     | config.ps1 | DSC configuration run on remote server and debugged. |
| Debugging     | longrunning.ps1 | Simple script that runs for long time allowing time to debug into it. |
| DevOps	| Assert-SiteTests.ps1 | Sample script that performs basic CI functionality for Pester and Script Analyzer scripts.|
| DevOps	| Pester.ps1 | Sample execution of pester against website configuration and resources. |
| DevOps	| ScriptAnalyzer.ps1 | Sample execution of Script Analyzer tests against website configurations and resources. |
| DevOps\Website | * | Sample website content and resources used for testing. |
| DevOps\Website\Tests | WebsiteConfig.Tests.ps1 | Sample unit tests for website configuration. |
| PullServer | 01 - PullServer Config.ps1 | Sample configuration used to deploy V2 pull server. |
| PullServer | 01 - PullServer Config.ps1 | Sample configuraiton used to deploy V2 pull server and sample PullServer WebApp. |
| PullServer | *.xml | CliXML files used to pass credentials into scripts. Replace these with your own CliXML files in order to run sample scripts successfully. |
| PullServer | Assert-PullServer.ps1 | Script use to deploy dsc configuration which configures the V2 Pull Server. |
| PullServer | Assert-TargetNode.ps1 | Script used to deploy meta-configuration to target node which tells it to get its configuration from the v2 pull server. |
| PullServer | Fabricam_ssl.* | SSL Certficates used to configure pull server to use HTTPS. |
| PullServer | Setup.ps1 | Script used to do initial configuration of demo environment. |
| PullServer | TargetNodeConfigs.ps1 | Configuration which generates target noded configurations that are posted to the pull server for retrieval by target node. |
| PullServer | TargetNodeMetaConfig.ps1 | Meta-Configuration script for target nodes which will point them to the pull server. |
| PullServer\Assets | * | Contains Pull Server ASP.Net WebApp content. |
| PullServer\Modules | * | Modules required for configurations. Copy these to your modules directory in order to execute scripts. |
| PullServer\V1 | * | Sample configurations and scripts demonstarting target node configuration and resulting mofs for pull server version 1. |

##Also see
[DSC Pull Server UI](https://github.com/grayzu/DSC-Pull-Server-UI) repo for the sample application source code.

repository: AnsgarGeers/Examples

repo_name: AnsgarGeers/Examples


text:
# Array Flatten

> Array flatten helper function, that uses recursion to flatten nested arrays.

### flatten

Deep flattens an array.

Use recursion.
Recursively flatten each element that is an array.

```js
const flatten = (arrayToFlatten) => {
  return Array.isArray(arrayToFlatten) ?
    [].concat(...arrayToFlatten.map(arrayMember => (Array.isArray(arrayMember) ? flatten(arrayMember) : arrayMember))) :
    []
};
```

<details>
<summary>Examples</summary>

```
deepFlatten([1, [2], [[3], 4], 5]); // [1,2,3,4,5]
```
</details>

[Repo link](https://github.com/rasha08/array-flatten)


text:
# Trixter Web

Trixter Web is a (very simple) web frontend for the Trixter Dream Bike.
Currently, the interface shows the difficulty (level of resistance) and
the rotations per minute of the pedals.

More will come soon.

## Installation

Follow the instructions for installing the trixter gem
(https://github.com/tommetge/trixter). Once you've installed this
dependency, then clone this repo and:

```
bundle install
ruby init.rb
```

Note: You need to plug in your XDream before starting the UI.

## Screenshot

Yeah, it's pretty much obligatory. Theme credits go to Alex Vanderzon
(https://creativemarket.com/alex_vanderzon/1754-Creative-Portfolio-HTMLCSS)

![Screenshot](https://github.com/tommetge/trixter-web/raw/master/public/assets/img/screenshot.png "Screenshot")

## Feedback

If you have any ideas, suggestions, or find some squishy bugs, give
me a shout by filing an issue.

repository: tommetge/trixter-web

repo_name: tommetge/trixter-web


text:
There are several ways to contribute to Asteroid.

## Improving the source code
#### Filterbanks
Analysis-synthesis
* [x] STFT (See unit tests)
* [x] Free e.g fully learned ([Luo et al.](https://arxiv.org/abs/1711.00541))
* [x] Analytic free e.g fully learned under analycity constraint ([Pariente et al.](https://<IP_ADDRESS>/abs/1910.10400))
* [x] Parametrized Sinc ([Pariente et al.](https://<IP_ADDRESS>/abs/1910.10400))

Analysis only (can be extended)
* [ ] Fixed Multi-Phase Gammatones ([Ditter et al.](https://arxiv.org/abs/1910.11615))
* [ ] Parametrized modulated Gaussian windows ([Openreview](https://openreview.net/forum?id=HyewT1BKvr))
* [ ] Parametrized Gammatone ([Openreview](https://openreview.net/forum?id=HyewT1BKvr))
* [ ] Parametrized Gammachirp ([Openreview](https://openreview.net/forum?id=HyewT1BKvr))

#### Separator
* [ ] Tasnet
* [ ] Deep clustering architecture
* [x] ConvTasNet
* [ ] FurcaNeXt
* [x] DualPath RNN

#### Losses
* [x] Scale Invariant SDR
* [ ] Deep clustering loss
* [ ] Backpropagable STOI
* [ ] Backpropagable PESQ

## Improving the docs.
To come.

## Writing new recipes.
To come.

## Guidelines
Simple : it needs to comply with PEP8. More to come.


text:
# Laravel Responses

[![Latest Version on Packagist][ico-version]][link-packagist]
[![Total Downloads][ico-downloads]][link-downloads]

A package to provide some standardized response classes.

## Installation

This package supports Laravel 6, 7, 8 and 9 but requires **at least** PHP 8.0. PHP 7.4 is supported up to version 2.1.1.

Via Composer

``` bash
$ composer require egeatech/laravel-responses
```

## Usage

Simply return a new instance of either `ApiResponse` or `PaginatedApiResponse` from your controller method.

Both classes share a similar signature for their constructors:

Here is the constructor for `ApiResponse`:

```php
public function __construct(
    # Either null, a valid Eloquent model or an \Illuminate\Support\Collection instance or a generic payload
    mixed $responseData,

    # A classFQN extending Laravel JsonResource instance, to be used to know how to map response data. Can be null if data don't need formatting.
    ?string $responseFormatter,

    # A valid HTTP status code, to be returned to the caller
    int $httpStatus = \Illuminate\Http\JsonResponse::HTTP_OK,

    # An optional ApplicationException instance, to properly provide a valid error message representation
    ?\EgeaTech\LaravelExceptions\Interfaces\Exceptions\LogicErrorException $logicException = null
) {}
```

And here the one for `PaginatedApiResponse` class:

```php
public function __construct(
    # A standard Laravel paginator instance, holding both data and pagination information
    \Illuminate\Contracts\Pagination\LengthAwarePaginator $paginatorData,

    # A classFQN extending Laravel JsonResource instance, to be used to know how to map response data
    string $responseFormatter,

    # A valid HTTP status code, to be returned to the caller
    int $httpStatus = \Illuminate\Http\JsonResponse::HTTP_OK,

    # An optional ApplicationException instance, to properly provide a valid error message representation
    ?\EgeaTech\LaravelExceptions\Interfaces\Exceptions\LogicErrorException $logicException = null
) {}
```

An example usage for the `ApiResponse` class could be the following:

```php
<?php

namespace App\Http\Controllers\Api\TestController;

use App\Http\Controllers\Controller;
use App\Http\Requests\ModelUpdateRequest;
use EgeaTech\LaravelResponses\Http\Responses\ApiResponse;
use EgeaTech\LaravelExceptions\Interfaces\Exceptions\LogicErrorException;

class TestController extends Controller
{
    public function __invoke(ModelUpdateRequest $request): ApiResponse
    {
        $occurredException = null;
        $databaseModel = null;

        try {
            $modelData = $request->validated();
            $databaseModel = $this->updateModel($modelData);
        } catch (LogicErrorException $exception) {
            $occurredException = $exception;
        }

        return new ApiResponse(
            $databaseModel,
            DatabaseModelResource::class,
            $occurredException
                ? $occurredException->getCode()
                : ApiResponse::HTTP_ACCEPTED,
            $occurredException
        );
    }
}
```

For the other class, its usage is the same as long as you provide a `LenghtAwarePaginator` instance as first parameter.

## Change log

Please see the [CHANGELOG](CHANGELOG.md) for more information on what has changed recently.

## Contributing

Please see [CONTRIBUTING](CONTRIBUTING.md) for details.

## Security

If you discover any security related issues, please email author email instead of using the issue tracker.

## Credits

- [Egea Tecnologie Informatiche][link-author]
- [Enrico<EMAIL_ADDRESS>- [Marco<EMAIL_ADDRESS>
## License

The software is licensed under MIT. Please see the [LICENSE](LICENSE.md) file for more information.

[ico-version]: https://img.shields.io/packagist/v/egeatech/laravel-responses.svg?style=flat-square
[ico-downloads]: https://img.shields.io/packagist/dt/egeatech/laravel-responses.svg?style=flat-square

[link-packagist]: https://packagist.org/packages/egeatech/laravel-responses
[link-downloads]: https://packagist.org/packages/egeatech/laravel-responses
[link-author]: https://egeatech.com

repository: EgeatechSRL/laravel-responses

gha_language: PHP

gha_license_id: NOASSERTION

repo_name: EgeatechSRL/laravel-responses


text:
### [CVE-2020-12674](https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2020-12674)
![](https://img.shields.io/static/v1?label=Product&message=n%2Fa&color=blue)
![](https://img.shields.io/static/v1?label=Version&message=n%2Fa&color=blue)
![](https://img.shields.io/static/v1?label=Vulnerability&message=n%2Fa&color=brighgreen)

### Description

In Dovecot before <IP_ADDRESS>, sending a specially formatted RPA request will crash the auth service because a length of zero is mishandled.

### POC

#### Reference
- https://hackerone.com/reports/866605

#### Github
- https://github.com/imhunterand/hackerone-publicy-disclosed

repository: trickest/cve

repo_name: trickest/cve


text:
## Resources

- [ngrx/store on github](https://github.com/ngrx) (Includes sample app)
- [Detailed walk through](https://gist.github.com/btroncone/a6e4347326749f938510)
- [Intro by the authors (April 7, 2017)](https://www.youtube.com/watch?v=cyaAhXHhxgk) ~40 min, time well spend
- [The full Reactive specifications](http://reactivex.io/)
-

repository: Stwissel/presentations

repo_name: Stwissel/presentations