Shared posts

07 Aug 18:32

Pedido Inesperado

Pedido Inesperado

O sonho de todo entregador HuAUShUAshUAshAUSa

04 May 14:52

Parem O Avião Eu Quero Descer

06 Dec 02:15

DeepMind’s Latest AI Trounces Human Players at the Game ‘Stratego’

by Shelly Fan

AI hates uncertainty. Yet to navigate our unpredictable world, it needs to learn to make choices with imperfect information—as we do every single day.

DeepMind just took a stab at solving this conundrum. The trick was to interweave game theory into an algorithmic strategy loosely based on the human brain called deep reinforcement learning. The result, DeepNash, toppled human experts in a highly strategic board game called Stratego. A notoriously difficult game for AI, Stratego requires multiple strengths of human wit: long-term thinking, bluffing, and strategizing, all without knowing your opponent’s pieces on the board.

“Unlike chess and Go, Stratego is a game of imperfect information: players cannot directly observe the identities of their opponent’s pieces,” DeepMind wrote in a blog post. With DeepNash, “game-playing artificial intelligence (AI) systems have advanced to a new frontier.”

It’s not all fun and games. AI systems that can easily maneuver the randomness of our world and adjust their “behavior” accordingly could one day handle real-world problems with limited information, such as optimizing traffic flow to reduce travel time and (hopefully) quenching road rage as self-driving cars become ever more present.

“If you’re making a self-driving car, you don’t want to assume that all the other drivers on the road are perfectly rational, and going to behave optimally,” said Dr. Noam Brown at Meta AI, who wasn’t involved in the research.

DeepNash’s triumph comes hot on the heels of another AI advance this month, where an algorithm learned to play Diplomacy—a game that requires negotiation and cooperation to win. As AI gains more flexible reasoning, becomes more generalized, and learns to navigate social situations, it may also spark insights into our own brains’ neural processes and cognition.

Meet Stratego

In terms of complexity, Stratego is a completely different beast compared to chess, Go, or poker—all games that AI has previously mastered.

The game is essentially capture the flag. Each side has 40 pieces they can place at any position on the board. Each piece has a different name and numerical rank, such as “marshal,” “general,” “scout,” or “spy.” Higher ranking pieces can capture lower ones. The goal is to eliminate the opposition and capture their flag.

Stratego is especially challenging for AI because players can’t see the location of their opponents’ pieces, both during initial setup and throughout gameplay. Unlike chess or Go, in which each piece and movement is in view, Stratego is a game with limited information. Players must “balance all possible outcomes” any time they make a decision, the authors explained.

This level of uncertainty is partly why Stratego has stumped AI for ages. Even the most successful game-play algorithms, such as AlphaGo and AlphaZero, rely on complete information. Stratego, in contrast, has a touch of Texas Hold ’em, a poker game DeepMind previously conquered with an algorithm. But that strategy faltered for Stratego, largely because of the length of game, which unlike poker, normally encompasses hundreds of moves.

The number of potential game plays is mind-blowing. Chess has one starting position. Stratego has over 1066 possible starting positions—far more than all the stars in the universe. Stratego’s game tree, the sum of all potential moves in the game, totals a staggering 10535.

“The sheer complexity of the number of possible outcomes in Stratego means algorithms that perform well on perfect-information games, and even those that work for poker, don’t work,” said study author Dr. Julien Perolat at DeepMind. The challenge is “what excited us,” he said.

A Beautiful Mind

Stratego’s complexity means that the usual strategy for searching gameplay moves is out of the question. Dubbed the Monte Carlo tree search, a “stalwart approach to AI-based gaming,” the technique plots out potential routes—like branches on a tree—that could result in victory.

Instead, the magic touch for DeepNash came from the mathematician John Nash, portrayed in the film A Beautiful Mind. A pioneer in game theory, Nash won the Nobel Prize for his work for the Nash equilibrium. Put simply, in each game, players can tap into a set of strategies followed by everyone, so that no single player gains anything by changing their own strategy. In Statego, this brings about a zero-sum game: any gain a player makes results in a loss for their opponent.

Because of Stratego’s complexity, DeepNash took a model-free approach to their algorithm. Here, the AI isn’t trying to precisely model its opponent’s behavior. Like a baby, it has a blank slate, of sorts, to learn. This set-up is particularly useful in early stages of gameplay, “when DeepNash knows little about its opponent’s pieces,” making predictions “difficult, if not impossible,” the authors said.

The team then used deep reinforcement learning to power DeepNash, with the goal of finding the game’s Nash equilibrium. It’s a match made in heaven: reinforcement learning helps decide the best next move at every step of the game, while DeepNash provides an overall learning strategy. To evaluate the system, the team also engineered a “tutor” using knowledge from the game to filter out obvious mistakes that likely wouldn’t make real-world sense.

Practice Makes Perfect

As a first learning step, DeepNash played against itself in 5.5 billion games, a popular approach in AI training dubbed self-play.

When one side wins, the AI gets awarded, and its current artificial neural network parameters are strengthened. The other side—the same AI—receives a penalty to dampen its neural network strength. It’s like rehearsing a speech to yourself in front of a mirror. Over time, you figure out mistakes and perform better. In DeepNash’s case, it drifts towards a Nash equilibrium for best gameplay.

What about actual performance?

The team tested the algorithm against other elite Stratego bots, some of which won the Computer Stratego World Championship. DeepNash squashed its opponents with a win rate of roughly 97 percent. When unleashed against Gravon—an online platform for human players—DeepNash trounced its human opponents. After over two weeks of matches against Gravon’s players in April this year, DeepNash rose to third place in all ranked matches since 2002.

It shows that bootstrapping human play data to AI isn’t needed for DeepNash to reach human-level performance—and beat it.

The AI also exhibited some intriguing behavior with the initial setup and during gameplay. For example, rather than settling on a particular “optimized” starting position, DeepNash constantly shifted the pieces around to prevent its opponent from spotting patterns over time. During gameplay, the AI bounced between seemingly senseless moves—such as sacrificing high-ranking pieces—to locate the opponent’s even higher-ranking pieces upon counterattack.

DeepNash can also bluff. In one play, the AI moved a low-ranking piece as if it were a high-ranking one, luring the human opponent to chase after the piece with its high-ranking colonel. The AI sacrificed the pawn, but in turn, lured the opponent’s valuable spy piece into an ambush.

Although DeepNash was developed for Stratego, it’s generalizable to the real-world. The core method can potentially instruct AI to better tackle our unpredictable future using limited information—from crowd and traffic control to analyzing market turmoil.

“In creating a generalizable AI system that’s robust in the face of uncertainty, we hope to bring the problem-solving capabilities of AI further into our inherently unpredictable world,” the team said.

Image Credit: Derek Bruff / Flickr

21 Oct 21:58

Testando O Doguinho

09 Jul 14:22

Secretário promete estação Varginha “pronta até o final do ano”

by Renato Lobo
Em uma cerimônia tímida, autoridades do estado entregaram um novo viaduto ferroviário junto a Estação Mendes – Vila Natal, na Linha 9-Esmeralda do sistema de trens metropolitanos. A estação, que passa a operar em horário integral neste sábado, faz parte da extensão da Linha 9 até Varginha. Por falar na futura estação, o secretário dos […]
19 Mar 21:05

Sua Avó Faz Bolinho De Chuva?

A minha faz isso! SEXTOU! HuASuAHSUAshAUsha

13 Jan 18:32

Após desativar sistema de trólebus, Moscou recebe 600º ônibus elétrico

by Renato Lobo
A Moscow Transport começo o ano de 2021 com seu 600º ônibus elétrico para a capital, um ano após desativar seu sistema de trólebus, que era um dos maiores do mundo. Eram cerca de 649 ônibus que rodam em quase 600 km de malha de rede elétrica. Após desativar os consagrados coletivos com os coletores, as […]
14 Aug 15:57

Nos anos 90, trem turístico ligava a estação Barra Funda e Campinas até Peruíbe

by Renato Lobo
O atual Expresso Turístico da CPTM é disputado, ao ponto de ter lista de espera. Liga a estação da Luz a três destinos, sendo Paranapiacaba, Jundiaí e Mogi das Cruzes. Mas, até o final dos 90, um outro serviço ligava a cidade de São Paulo e Campinas até a Baixada Santista, em Peruíbe. O Trem […]
26 Feb 12:45

Error or Plunder? Report Suggests FCoin Purposely Moved Customer Bitcoin Since 2019

by Daniel Cawrey
A recent report from Silicon Valley-based Anchain AI wonders out loud whether funds were purposely pilfered by insiders, challenging FCoin’s official line claiming a data error was to blame.
03 Sep 16:53

Samsung Is Secretly Working on a Foldable Phone That Collapses Into a Square

by msmash
Samsung is preparing to unveil its second foldable device early next year, a luxury phone that folds down into a compact-sized square. From a report: The South Korean smartphone giant is working on a device with a 6.7-inch inner display that shrinks to a pocketable square when it's folded inward like a clamshell, according to people familiar with the product's development. Samsung is seeking to make its second bendable gadget more affordable and thinner than this year's Galaxy Fold, they said. The launch of the successor device may, however, hinge on how well the Fold performs after its imminent launch, one of the people said. Samsung is collaborating with American designer Thom Browne on its upcoming foldable phone, endeavoring to appeal to a broader range of consumers that includes those more interested in fashion, status and luxury than a device's tech specs. For the techies, it will sport cutting-edge display technology and the nostalgic appeal of rejuvenating the flip-phone. The new foldable phone will have a hole-punch selfie camera at the top of the inner display, just as on the recently released Samsung Galaxy Note 10, according to one person familiar with the device. On the outside, it will have two cameras that face the rear when the phone is open or the front when it's flipped closed.

Share on Google+

Read more of this story at Slashdot.

21 Aug 19:31

MoviePass Exposed Thousands of Unencrypted Customer Card Numbers

by msmash
New submitter sizzlinkitty writes: Movie ticket subscription service MoviePass has exposed tens of thousands of customer card numbers and personal credit cards because a critical server was not protected with a password. Mossab Hussein, a security researcher at Dubai-based cybersecurity firm SpiderSilk, found an exposed database on one of the company's many subdomains. The database was massive, containing 161 million records at the time of writing and growing in real time. Many of the records were normal computer-generated logging messages used to ensure the running of the service -- but many also included sensitive user information, such as MoviePass customer card numbers. These MoviePass customer cards are like normal debit cards: they're issued by Mastercard and store a cash balance, which users who sign up to the subscription service can use to pay to watch a catalog of movies.

Share on Google+

Read more of this story at Slashdot.

09 Aug 02:55

O Fim De Uma Saga

O Fim De Uma Saga

Pelo menos no carro ela não esquece mais HuASuhASuAHSuAHs

05 Dec 13:32

Amazon Promised Drone Delivery In Five Years Five Years Ago

by BeauHD
On December 1, 2013, Amazon announced its plans to deliver packages by drone in just "four or five years" on a 60 Minutes episode with then-host Charlie Rose. As The Associated Press reports, it's officially been five years and drone deliveries seem to be nowhere in sight. "Bezos made billions of dollars by transforming the retail sector," reports The Associated Press. "But overcoming the regulatory hurdles and safety issues posed by drones appears to be a challenge even for the world's wealthiest man." From the report: The day may not be far off when drones will carry medicine to people in rural or remote areas, but the marketing hype around instant delivery of consumer goods looks more and more like just that -- hype. Drones have a short battery life, and privacy concerns can be a hindrance, too. Amazon says it is still pushing ahead with plans to use drones for quick deliveries, though the company is staying away from fixed timelines. "We are committed to making our goal of delivering packages by drones in 30 minutes or less a reality," says Amazon spokeswoman Kristen Kish. The Seattle-based online retail giant says it has drone development centers in the United States, Austria, France, Israel and the United Kingdom.

Share on Google+

Read more of this story at Slashdot.

22 Sep 17:10

Quando Ela Te Elogia ♥

Quando Ela Te Elogia

Mas é braba demais pra deixar quieto HuAUShAUShAUsAHS

28 May 11:14

5 Free Token Airdrops You Can Claim Now

by Bruno Skvorc

Airdrops are a great marketing tactic used by various cryptocurrency projects to increase liquidity and adoption, as well as drive Google traffic. Some projects drop tokens into your accounts without being prompted, while others, arguably more legit ones, require you to register on a specific website and maybe go through a KYC procedure as well.

A notable example is the Ontology airdrop which occurred earlier this year and happened for everyone who subscribed to their newsletter in time. All subscribers got 1000 tokens plus 10% of their NEO amount in ONT dropped into their addresses, and at a current price of almost $8, down from an all-time high of $10.50, a lot of people got $8,000-$10,000+ for no more than a newsletter signup.

Let's take a quick look at five airdrop projects you can sign up for today which may or may not be the next Ontology in your portfolio!

1. Profede

Profede is a tool for independent professionals looking for freelance or permanent work which lets both businesses and individuals cut down on fees by paying intermediaries less (hiring referral fees can climb to many thousands of dollars) and individuals more.

You can read about the project on their website, or sign up for their airdrop via this link.

2. OPU

A project touching on my area of expertise, OPU is a project aiming to tokenize skincare management. While many medical ICO projects exist, this one is specific in that it aims to make blockchain-based sharing of skin condition issues a possibility, allowing for machine learning on a wider variety of samples for automated detection, targeting for advertisement and clinical trials, and most of all, user control over their own data. Instead of relying on one platform to keep it safe, users can sell their skin data for OPU tokens.

You can sign up for their airdrop at this link.

3. Etherc.io

Etherc.io is a new decentralized exchange on the Ethereum blockchain which aims to put control fully into the hands of users with gas-free trading.

Many will remember the Binance coin when it first came out - it was in the sub-dollar price, whereas now it's not uncommon to see it above $10. Exchange coins are popular because they offer a good hedging mechanism in times of volatility, and because they're highly liquid.

You can sign up for the airdrop at this link.

4. ARAW

The ARAW token is a "Decentralized Payment for E-Commerce Ecosystem". It's mission is to enable users to send and receive crypto payments easily, including microtransactions, contactless payments in stores through their own cards, end-to-end solutions for end users and merchants, and a whole ecosystem surrounding the need for a business to start accepting payments in whatever currency they choose. The token will be an in-between medium of exchange from currency to currency, fostering liquidity.

You can read more on their website or sign up for the airdrop at this link.

5. AITHEON

Aitheon aims to bridge the robot-human gap by providing a dynamic marketplace of skilled robot operators and AI trainers and robotic workers. Think of it as a community-powered robot-training-ground where people help companies operate and train their robots, and those workers are paid with Aitheon tokens.

You can read about other utilities of this token over on their website, but in the meantime, go ahead and sign up for the airdrop on this link - it'll require passing a KYC process, but that also gives the project much more legitimacy.

Continue reading %5 Free Token Airdrops You Can Claim Now%

13 Oct 17:06

No Token Response: UNICEF Is Open to Doing Its Own ICO

by Michael del Castillo
A UNICEF ICO? The idea doesn't seem so far-fetched to those working at the United Nations programme, despite their humanitarian mandate.
03 Sep 22:17

5 Reasons the UN Is Jumping on the Blockchain Bandwagon

by Scott Simonsen

By the time they woke on May 31st, 2017, 10,000 Syrian refugees stationed at Azraq camp in Jordan had received their long-awaited aid. But instead of the typical white and blue trucks from the United Nations’ World Food Program (WFP), the aid came in the form of electronic vouchers distributed on the back of a rapidly-growing technology called blockchain, specifically the Ethereum blockchain.

Thanks to this venture’s resounding success, several UN agencies have taken notice, prompting claims that blockchain could not only be used to distribute aid to refugees across the world, but for several other philanthropic purposes too.

What Is the Ethereum Blockchain?

Ethereum is a cryptocurrency, much like the more popular Bitcoin. Cryptocurrencies function largely like traditional currencies but are entirely digital, heavily encrypted, and can be stored on and transferred with electronic devices. One of the key selling points is that they’re not controlled by a central authority, such as the US Federal Reserve Bank, meaning the currency’s amount is strictly limited to preset logarithmic growth and its value is entirely determined by market demand.

The risk of wild inflation or deflation is minimized, and the currency can be more easily transferred across borders—although this can enable criminals, as financial transactions cannot be traced as easily as they can through the heavily-regulated traditional financial system.

The technology underlying cryptocurrencies is blockchain, a public ledger that records all transactions and uses private key cryptography and peer-to-peer networking to ensure secure decentralized distribution.

The UN explains blockchain as “a distributed database that is continuously updated and verified by its users. Each added block of data is ‘chained’ and becomes part of a growing list of records, under the surveillance of network members. This technology enables the transfer of assets and the recording of transactions through a secure database.”

UN aid efforts have a historic problem of fraud, mismanagement, and bureaucratic red tape, but with the ability to circumnavigate governments and banking institutions, transferring aid via blockchain can be far more efficient.

This is especially true for the Ethereum blockchain. It is Turing complete, meaning it has its own internal code and can execute any algorithm given enough time and memory. This makes it more adaptable, allowing it to transfer just about anything, not only cryptocurrencies.

How Can It be Used by the UN?

Distributing Aid

As mentioned above, the World Food Program is already using the Ethereum blockchain in a pilot program called Building Blocks to distribute vouchers for food to refugees in Jordan. There are plans to expand the program to refugees in the other eighty countries where the WFP operates.

But this is just the beginning. Experts are brainstorming how to take advantage of the Ethereum blockchain’s adaptability.

Climate Change

At the UN Climate Conference in Bonn, Germany last May, using the Ethereum blockchain was proposed to help combat climate change. Alexandre Gellert Paris, an officer of the UN’s Framework Convention on Climate Change, claimed that “blockchain could contribute to greater stakeholder involvement, transparency and engagement and help bring trust and further innovative solutions in the fight against climate change, leading to enhanced climate actions.”

More specifically, blockchain could be used to facilitate trading of carbon assets, the owner of which has the right to emit a predefined amount of greenhouse gases. Companies can buy and sell these like any other asset, and this market can benefit from the increased efficiency and transparency of the Ethereum blockchain. In fact, IBM and a new organization called Energy Blockchain Lab are currently trying to adapt the blockchain to China’s carbon trading market.


Furthermore, some experts at the UN Climate Conference suggested blockchain could be used to develop peer-to-peer renewable energy trading platforms where governments, businesses, and civilians would be able to buy and sell digital assets that represent a certain amount of energy production. They have also proposed that this could facilitate crowdfunding for renewable projects, as well as enhance tracking the reduction of greenhouse gases in accordance with the Nationally Determined Contributions spelled out in the Paris Agreement.

Identity

Currently, over a billion people are not officially recognized by a government, meaning they cannot enjoy the protection and services afforded to citizens of a state, such as access to education, health care, voting, the ability to open a bank account, etc. The UN considers this one of the major problems facing the world today, prompting them to begin measures to “provide legal identity to all, including birth registration, by 2030.” So far, this has proven to be more difficult than originally envisioned.

But the ID2020 Alliance—a new organization composed of UN agencies, non-profits, companies, governments, and other enterprises—believe they can meet this goal by building a digital ID network on the back of the Ethereum blockchain. During the organization’s second summit at the UN headquarters last June, Accenture and Microsoft presented a prototype that would make identity personal, persistent, portable, and private. That is, it would be unique to only one person, live with a person from life to death, be accessible from anywhere, and could only be given out with permission.

Remittances

The UN estimates around 200 million migrant workers send money across borders to support close to 800 million family members, totaling more than 400 billion dollars in 2016. According to the UN’s International Fund for Agricultural Development (IFAD), this is responsible for lifting millions out of poverty, as the money is spent on needs like food, healthcare, housing, education, and sanitation. Unfortunately, transaction costs to send remittances currently exceed $30 billion annually, with fees particularly high to the poorest countries and remote rural areas.

The Ethereum blockchain, without a central authority or middleman, allows for free transactions, thus eliminating this billion-dollar burden. It also provides increased speed, ease of use, and more privacy for both senders and receivers. IFAD and other UN organizations that deal with remittances are actively researching how to apply the Ethereum blockchain.

Smart Contracts

The UN’s International Children’s Emergency Fund (UNICEF) is considering employing the Ethereum blockchain to increase transparency and reduce what they call the “cost of trust.” Because of the difficulty of tracking international transactions and because UNICEF conducts so many of them, they suffer from some degree of mismanagement, including the potential for fraud.

This can be solved by using smart contracts, as suggested by UNICEF Ventures, a branch dedicated to improving the organization’s ability to move funds. Smart contracts work like a normal contract, in which two or more parties enter an agreement, but instead of having a third party to enforce it, the contract is executed entirely on blockchain, rendering a third party irrelevant.

For example, if person A wants to buy a website’s password from person B, they could enter into a contract in which the password is released only when the agreed amount of cryptocurrency has been transferred. The transaction would be on the public ledger, giving it far more transparency and making it more efficient, thus helping UNICEF overcome its transparency problem and function more smoothly.

More to Come

Since its release in July 2015, the Ethereum blockchain has garnered significant attention as people and organizations of all types have begun to imagine virtually unlimited ways to take advantage of the transparency, security, and efficiency it offers. The UN in particular has embraced it, with seven UN agencies either investigating or implementing it for various purposes. In fact, a major summit is scheduled for the beginning of October at UN Headquarters in New York, in which the Digital Blue Helmets, the UN’s branch of technology experts, are expected to unveil some exciting new applications of the Ethereum blockchain.

Stock Media provided by palinchak / Pond5

03 Apr 23:47

Why Kirby Is Low-Tier in Super Smash Brothers

by Maddy Myers on Compete, shared by Maddy Myers to Kotaku

Kirby is a controversial character, especially among competitive Super Smash Brothers players.

Read more...

22 Feb 01:37

React Storybook: Develop Beautiful User Interfaces with Ease

by Pavels Jelisejevs

React Storybook

When you start a new front-end project, the first thing you usually do is create a beautiful design. You carefully plan and draw all of your UI components, as well as each state or effect they may have. However, during development, things usually start to change. New requirements, as well as unforeseen use cases pop up here and there. The initial beautiful component library cannot cover all of these requirements and you start to expand it with new designs.

It's good if at this point you still have a design expert around, but all too often they have already switched to a different project and left the developers to cope with these changes. As a result, the consistency of the design begins to slip. It becomes difficult to track what components you already have in your library and what states and appearances they may have.

To avoid this artistic mess it's usually a good idea to create separate documentation for all of your components. There are various tools for such purposes, but in this article, we'll focus on a tool designed particularly for React applications — React Storybook. It allows you to easily browse your collection of components and their functionality. A living example of such an app is the gallery of React Native components.

Why Do You Need React Storybook?

So how does this showcase help? To answer this question, let's try to put together a list of people who take part in the development of UI components and assess their needs. Depending on your workflow this list might differ, but the usual suspects are the following:

Designer or UX expert

This is the person responsible for the look and feel of the user interface. After the mockup phase of the project is finished, often the designer leaves the team. When new requirements arise, they need to quickly catch up on the current state of the UI.

Developer

The developer is the one who creates these components and probably the main beneficiary of a style guide. The two major use cases for the developer are being able to find a suitable component from the library and be able to test them during development.

Tester

This is the meticulous person who makes sure the components are implemented as expected. A major part of a tester's work is making sure that a component behaves correctly in every way. And although this does not eliminate the need for integration testing, this is often more convenient to do separately from the project itself.

Product owner

The person who accepts the designs and the implementation. The product owner needs to make sure each part of the project looks as expected and that the brand style is represented in a consistent manner.

You've probably noticed that a common denominator for everybody involved, is having a single place containing all of the components at once. Finding all of them in the project itself can be quite tedious. Think about it, how long will it take you to find all possible variations of buttons in your project, including their states (disabled, primary, secondary etc)? That's why having a separate gallery is much more convenient.

If I've managed to convince you, let's see how we can set up Storybook in a project.

Setting up React Storybook

To set up React Storybook the first thing you'll need is a React project. If you don't have a suitable one at the moment, you can easily create one using create-react-app.

To generate a Storybook, install getstorybook globally

npm i -g getstorybook

Then navigate to your project and run

getstorybook

This command will do three things:

  • Install @kadira/storybook into your project.
  • Add the storybook and build-storybook scripts to your package.json file.
  • Create a .storybook folder which contains the basic configuration and a stories folder with a sample component and story.

To run Storybook, execute npm run storybook and open the address displayed (http://localhost:9009/). The app should look like this:

React Storybook Default User interface

Adding New Content

Now that we have React Storybook running, let's see how we can add new content. Each new page is added by creating stories. These are snippets of code that render your component. An example story generated by getstorybook looks like this

//src/stories/index.js

import React from 'react';
import { storiesOf, action, linkTo } from '@kadira/storybook';
import Button from './Button';
import Welcome from './Welcome';

storiesOf('Welcome', module)
  .add('to Storybook', () => (
    <Welcome showApp={linkTo('Button')}/>
  ));

storiesOf('Button', module)
  .add('with text', () => (
    <Button onClick={action('clicked')}>Hello Button</Button>
  ))
  .add('with some emoji', () => (
    <Button onClick={action('clicked')}>   </Button>
  ));

The storiesOf function creates a new section in the navigation menu, and the add method creates a new subsection. You are free to structure the storybook however you see fit, but you cannot create hierarchies deeper then two levels. A straightforward approach to structuring your Storybook is creating common top-level sections such as "Form inputs", "Navigation" or "Widgets" for groups of related elements, and sub-sections for individual components.

You are free to choose where to place your story files: in a separate stories folder or next to the components. I, personally, prefer the latter since keeping the stories close to the components helps to keep them accessible and up to date.

Stories are loaded in the .storybook/config.js file which contains the following code:

import { configure } from '@kadira/storybook';

function loadStories() {
  require('../src/stories');
}

configure(loadStories, module);

By default, it loads the src/stories/index.js file and expects you to import your stories there. This is slightly inconvenient since it would require us to import each new story we create. We can modify this script to automatically load all of the stories using Webpack's require.context method. To distinguish story files from the rest of the code, we can agree to add a .stories.js extension to them. The modified script should look like this:

import { configure, addDecorator } from '@kadira/storybook';
import React from 'react';

configure(
  () => {
    const req = require.context('../src', true, /.stories.js$/);
    req.keys().forEach((filename) => req(filename));
  },
  module
);

configure(loadStories, module);

If you're using a different folder for your source code, make sure you point it to the correct location. Re-run Storybook for the changes to take effect. The Storybook will be empty since it no longer imports the index.js file, but we'll soon fix that.

Writing a New Story

Now that we've slightly tailored Storybook to our needs, let's write our first story. But first of all we need to create a component to showcase. Let's create a simple Name component to display a name in a colored block. The component will have the following JavaScript and CSS.

import React from 'react';

import './Name.css';

const Name = (props) => (
  <div className={'name ' + (props.type ? props.type : '')}>{props.name}</div>
)

Name.propTypes = {
  type: React.PropTypes.oneOf(['highlight', 'disabled']),
}

export default Name;
.name {
  display: inline-block;
  font-size: 1.4em;
  background: #4169e1;
  color: #fff;
  border-radius: 4px;
  padding: 4px 10px;
}

.highlight {
  background: #dc143c;
}

.disabled {
  background: #999;
}

As you've probably noticed, this simple component can have three states: default, highlighted and disabled. Wouldn't it be nice to visualize all of them? Let's write a story for that. Create a new Name.stories.js file alongside your component and add the following contents:

import React from 'react';
import { storiesOf, action, linkTo } from '@kadira/storybook';

import Name from './Name';

storiesOf('Components', module)
  .add('Name', () => (
    <div>
      <h2>Normal</h2>
      <Name name="Louie Anderson" />
      <h2>Highlighted</h2>
      <Name name="Louie Anderson" type="highlight" />
      <h2>Disabled</h2>
      <Name name="Louie Anderson" type="disabled" />
    </div>
  ))

Open Storybook and have a look at your new component. The result should look like this:

Name story

Feel free to play around with how the component is displayed as well as with its source. Note that thanks to React's hot reloading functionality, whenever you edit the story or the component, the changes will instantly appear in your Storybook without the need to manually refresh the browser. However refreshing might be required when you add or remove a file. Storybook doesn't always notice such changes.

Continue reading %React Storybook: Develop Beautiful User Interfaces with Ease%

08 Feb 21:40

Why Overwatch Players Are Excited About A Character Named 'Doomfist'

by Nathan Grayson

Doomfist, the name of a long-lost Disturbed album and probably also a villain in season 57 of Power Rangers, is today’s big Overwatch discussion topic. Some suspect that he’s gonna be a playable hero soon, but he’s technically been present in the game since day one.

Read more...

10 Jan 01:30

7 coisas que aprendi trabalhando no sistema prisional brasileiro

by Filipe Azevedo Rodrigues

* Filipe Azevedo Rodrigues está cursando Doutorado em Ciências Jurídico-Criminais na Universidade de Coimbra, em Portugal, e foi Diretor da Escola Penitenciária do Rio Grande do Norte.

Entrei no sistema prisional brasileiro com 22 anos de idade, no meu último ano de Curso de Direito numa prestigiada universidade pública brasileira. Soou muito esquisito para muitas pessoas próximas a mim ter prestado tal concurso e, enfim aprovado, passar a exercer o cargo de agente penitenciário. Mas no país do funcionalismo público o que vale é a “estabilidade”, em que pese o risco no qual estive envolvido.

Após cinco anos, exonerei-me do cargo e não me arrependo desse período, pois tive a sorte de conviver com bons profissionais e de ter lidado de forma correta com as crônicas crises vivenciadas.

O importante, por outro lado, foi o que aprendi – muita coisa. Assim, lanço mão das sete lições mais valiosas que pude tirar, sobretudo relacionadas com o colapso de décadas das prisões brasileiras, evidenciado nos últimos dias nos estados de Amazonas e Roraima.

1. O Crime Organizado é mais organizado que o Estado.

cadeia

A vida pode ser retratada nos cinemas, mas dificilmente Hollywood conseguiria traduzir a origem e evolução das organizações criminosas brasileiras.

Digo isso porque os enredos de máfias italianas e cartéis hispano-americanos pouco se aplicam ao nosso caso. As famosas organizações Comando Vermelho (CV) e Primeiro Comando da Capital (PCC) têm origem comum. Surgiram nos presídios brasileiros há décadas como grupos de presos que habitavam um ambiente prisional de muralhas e grades precárias, cárcere pelo cárcere.

A autopreservação ensejou os grupos e eles prosperaram em presídios abandonados como todo e qualquer serviço público brasileiro.

O curioso é que pouco mudou desde as décadas de setenta e oitenta, do alvorecer do crime organizado brasileiro para o surgimento das novas famílias e sindicatos do crime (nomes comuns às novas organizações).

Na verdade, a população carcerária é imensa e amontoa-se nos estabelecimentos penais. Alimentação, vestimenta, espaço para dormir, proteção e demais pormenores da vida no cárcere tornaram-se produtos fornecidos (ou permitidos) pelos antigos aos novos e a moeda vai desde a entrada de um celular na genitália de um familiar do apenado devedor a integrar determinado grupo e tirar a vida de um rival dentro da prisão.

Assim, o crime organizado se forma e se sofistica, passando a atuar e cobrar os débitos dos seus membros quando regressam à liberdade. Isto é: mata-se e rouba-se para pagar a proteção e alimentação recebidas na cadeia, sob pena de perder a vida na mão de um membro mais leal e em dia com as obrigações do grupo.

Como então não perceber que o dito sistema prisional gesta o crime organizado no Brasil?

A pergunta é necessária. O fato é que ele o produz e que a sua capacidade de retroalimentação foi potencializada nos últimos anos, a exemplo da famigerada matança da Família do Norte (então desconhecida), vitimando membros do PCC em Manaus (então conhecido como apenas o “Comando” da Capital de São Paulo).

2. Nós não fazemos a menor ideia de quem prendemos.

agencia-brasil170912wdo_3463

É comum ouvirmos que só se prende no Brasil “preto e pobre”. O mais interessante, no entanto, é não sabermos o quanto.

Certa vez, estive em um debate numa universidade sobre a crise no sistema prisional do Rio Grande do Norte. Nele, estava presente a Coordenadora para Igualdade Racial da Secretaria de Justiça do Estado. Na ocasião, afirmou-se que no Rio Grande do Norte os cárceres estavam superlotados de negros. O curioso foi que eu havia recebido no mesmo dia a fotografia de mais de trinta foragidos da maior penitenciária do Estado – e, entre eles, haviam apenas três negros.

A par de toda essa questão, o que me ficou na cabeça desde esse dia é que, de fato, não sabemos quem são os nossos presos. Não se sabe quantos estão no cárcere, muito menos quem são essas pessoas: naturalidade, estado civil, gênero, orientação sexual, profissão, renda, escolaridade, cor.

O próprio IBGE manifestou-se recentemente no sentido de que nunca houve um censo carcerário – e eu me pergunto se haveria a necessidade de o IBGE se prestar a isso. Afinal, bastava registrar essas informações básicas quando se prende alguém – e, então, alimentar um simples banco de dados virtual.

Faz-se o primeiro? Não. Funciona o banco de dados? Muito menos.

3. Nós não temos um “sistema” penitenciário.

ce03

Usa-se muito a palavra “sistema”, “sistema prisional”, “sistema penitenciário” ou apenas “o sistema”. Mas o erro geral já começa na falta de humildade em reconhecer que a palavra não pode ser aplicada ao que temos. Sistema pressupõe uma organização funcional e harmônica. E nele, órgãos e unidades devem operar de maneira integrada.

No Brasil, cada Estado tem sua estrutura prisional e seu espaço de jurisdição próprios, muitas vezes sem a devida comunicação. Isso porque dentro de um mesmo Estado não é raro encontrar realidades de completo caos organizacional. Os procedimentos mais simples e óbvios do funcionamento de um dado presídio, como as visitas, são invertidos de ponta à cabeça em outro estabelecimento penal na mesma cidade. Familiares e advogados passam semanas sem saber para onde foi transferido um preso e qual a razão que motivou a transferência, muitas vezes por mera desorganização.

Para o Estado, falta padronização de procedimentos e controle dos servidores penitenciários uniforme. Para os preso, sobra organização em âmbito nacional, vide o exemplo do PCC em Manaus.

4. O Estado não funciona para os cidadãos livres. Como iria funcionar para os presos?

limpeza_na_penitenciaria_2009_3_27_13_7_25-1

A precariedade em todos os serviços públicos, principalmente naqueles ditos essenciais como saúde e educação, não poderia condizer melhor com a incompetência estatal na gestão penitenciária. Não se consegue prestar um atendimento digno no SUS a um cidadão livre – por que raios conseguiríamos isso a quem está confinado em nossas prisões? Enquanto você lê esse texto, há doentes psiquiátricos, absolvidos judicialmente pela sua condição psicótica grave, que estão encarcerado com presos comuns, enquanto deveriam encontrar-se em hospitais, sendo tratado como pacientes, não como delinquentes.

Não é de se imaginar, de igual modo, que a educação seja transformadora no Brasil. Educar em presídios só é possível, em regra, se a organização criminosa que o arregimentou patrocine seus estudos.

5. Quem são os responsáveis pela crise?

congresso_1

Acho que você sabe perfeitamente essa resposta: o Estado é o responsável. Ponto. Mas nunca me conformei em ficar apenas nessa acusação abstrata. As leis brasileiras não são nem brandas, nem severas. Basta cuidar de pesquisar o que ocorre mundo afora para chegar a essa conclusão. O processo para se alcançar as punições, entretanto, não me parece muito racional e, sem dúvida, ele está assim posto na lei. Seria possível evitar muitas prisões se houvessem instâncias de solução de conflitos mais eficientes e aplicação de penas pecuniárias com maior celeridade para crimes contra o patrimônio e de menor potencial ofensivo, em especial.

Essa é uma parcela de responsabilidade do legislativo federal (deputados federais e senadores), que pouco se importa com os resultados da nossa política criminal – se importa muito mais com soluções demagógicas e populistas.

Mas as soluções imediatas estão, em princípio, nas mãos do Poder Executivo. A responsabilidade é dos Governadores dos Estado em gerir os estabelecimentos penais e dotá-los da estrutura mínima para que, pelo menos, evitem-se massacres como o de Manaus.

A União (Presidente da República e Ministro da Justiça) tem também seu papel, afinal conta com um fundo bilionário de recursos alimentados por diversas fontes (tal como a loteria federal), destinado ao sistema penitenciário. E a questão também envolve o fato de o acesso a tais recursos ter sido restringido nos últimos anos para compensar o déficit nas contas públicas federais. As gestões estaduais, em vários casos, costumam ser amadoras e suscetíveis à distribuição político-eleitoral dos cargos públicos e a União, por sua vez, sempre se acomodou na sua posição institucional de responsabilidade indireta, ao ponto de restringir o aporte financeiro devido – o que, sem dúvida, contribuiu para essas dezenas de mortes das últimas semanas.

Entretanto, a experiência me trouxe à tona um personagem ainda mais protagonista nessa história macabra das prisões brasileiras. Não há como deixar de encarar a responsabilidade de milhares de juízes que prendem compulsivamente antes mesmo de uma condenação, ao passo que negligenciam suas funções de contínuos fiscais dos estabelecimentos penais.

Explico melhor.

A prisão, em regra, é pena e, como tal, aplica-se àquelas pessoas condenadas pela prática de um dado crime. Mas existe a possibilidade de um juiz determinar o encarceramento por cautela ou prevenção, antes mesmo de um suspeito ser denunciado e tornar-se réu. São as chamadas prisões processuais. Estas têm sua importância, mas, conforme o nosso Direito e a lógica da coisa, deveriam ser usadas excepcionalmente, até porque não há dúvida que é possível e mais barato controlar os passos de suspeitos de crimes através de tecnologias muito mais simples e eficientes, como a monitoração eletrônica.

O problema reside justamente na falta de lógica na atuação de muitos magistrados durante a condução dessas investigações e processos. A prisão vira a regra e, muitas vezes, levam-se inocentes ou delinquentes sem envolvimento em crimes graves para aquela estrutura paralela montada nas cadeias brasileira, do pague e se alie ao crime organizado para sobreviver enquanto preso.

Praticamente 25% de todos os presos no Brasil encontram-se nessa situação – são presos processuais, legalmente inocentes, sem sentenças proferidas em processos inexplicavelmente lentos, de modo a contribuir para o alistamento obrigatório no crime organizado, tudo em razão do “na dúvida, prende”. Pode parecer mais fácil, mas o resultado está diante dos nossos olhos há tempos.

O outro lado da responsabilidade do Judiciário brasileiro está nas mãos dos juízes que acompanham as execuções das penas e a regularidade dos estabelecimentos prisionais.

Pois é, existem juízes com essa exclusiva atribuição: são os juízes da execução penal. Cada comarca brasileira com algum presídio nela instalado deve possuir um magistrado com tal função, sendo comum, nas maiores cidades, haver um ou mais juízes atuando nisso.

Dentro de suas atividades e deveres impostos por lei, cumpre aos juízes da execução penal inspecionar mensalmente os estabelecimentos penais sob sua responsabilidade, a fim de tomar as providências necessárias para seu regular funcionamento – devendo, inclusive, determinar a interdição do presídio e a apuração da responsabilidade de seus gestores (membros do Poder Executivo) quando constatada qualquer irregularidade. Quando foi a última visita dos juízes de Manaus ao Complexo Penitenciário Anísio Jobim? Não constaram irregularidades? Quais providências tomaram? O presídio foi interditado?

Essas perguntas, por óbvio, devem ser estendidas e permanentemente refeitas aos magistrados de todo país que desempenham e são remunerados para tal função.

6. Sim, um sistema penitenciário sustentável é perfeitamente possível.

presidio_1

Embora tudo que comentei até agora não seja de despertar esperança, não posso deixar de dizer que grandes crises também podem ser encaradas como momentos de mudança, de oportunidade.

Aprendi também que um verdadeiro sistema penitenciário pode perfeitamente ser sustentável e não pesar tanto nas contas pública e nos contribuintes.

Do ponto de vista jurídico, a Lei de Execução Penal brasileira é mais do que suficiente para isso. E ela dispõe de mecanismos interessantes.

Há a divisão do cumprimento da pena de prisão em três regimes progressivos, inspirados no modelo irlandês de cumprimento de pena. O primeiro é o chamado regime fechado, cuja prisão é cumprida em penitenciárias, estabelecimentos de segurança de custo mais elevados – mas é dever do Estado oferecer, já nesses ambiente, condições de profissionalização, educação e trabalho. Ultrapassado uma fração da pena com bom comportamento, o apenado faz jus à progressão ao regime semiaberto, em colônias agrícolas ou industriais penais, onde o trabalho é ainda mais evidenciado, desde o nome dados aos presídios desse regime. Por fim, completada mais uma fração da pena, o regime aberto é cumprido nas casas de albergado, que, conforme a Lei, recebem os apenados para o repouso noturno enquanto desempenham uma ocupação formal durante o dia (trabalho ou educação).

A chave da sustentabilidade, portanto, está no trabalho. A própria Lei oferece vários incentivos a todos os agentes envolvidos para que o trabalho efetivamente ocorra. Ao preso, a remição da pena: a cada três dias trabalhados, um dia a menos de pena. Ao Estado, não é necessário que ele ofereça os postos de trabalho, pois a Lei lhe permite conveniar com empresas privadas para recrutarem essa mão de obra. Às empresas, o preso pode ser remunerado em 75% do salário mínimo, desempenhando a mesma jornada de um empregado normal, porém sem direito a gozar e ser remunerado por férias, décimo terceiro salário ou fundo de garantia por tempo de serviço.

Brasil afora, algumas experiências nesse sentido vêm sendo bem sucedidas, sem contar o interesse de promoção da imagem e responsabilidade social de todos os envolvidos. O problema, entretanto, está, como visto, no cumprir a Lei ser somente “algumas experiências”. Não há, nos cárceres brasileiros, o hábito de cumprir a lei, o que dificulta bastante a missão de ressocializar os apenados.

Não posso fechar esse tópico, porém, sem apresentar a minha impressão justamente sobre o que, para mim, seria ressocializar, entre a utopia da expiação plena dos pecados e o negativismo dos que consideram criminosos de irrecuperáveis. A criminalidade brasileira como está posta evidencia que os criminosos não têm preço a pagar pela vida no crime. Não há custo de oportunidade em deixar de lado uma vida tida como honesta, pois inexiste essa opção. O estereótipo do criminoso habitual é jovem e ocioso, com pouco estudo, muitas vezes porque abandonou o colégio em meio a uma sociedade criminógena. Não há valor no trabalho lícito porque não se ensina e forma profissionais no Brasil. Aqueles afortunados que terminam o ensino superior já não são formados para alcançarem um posto de trabalho e desempenhar uma profissão de fato. O gap entre educação e trabalho no Brasil é demasiadamente grande e a massa de desempregados que nunca se interessaram por se empregar contribui bastante para o crime. O trabalho e a formação profissionalizante é, antes de meio de ressocialização, uma tentativa de socializar.

7. As soluções privadas como uma luz no fim do túnel.

151222095647__dsc2819

Acima, já ficou claro que o trabalho é central na (res)socialização dos apenados e o meio de viabilizá-lo conforme a Lei está na parceria entre o Poder Público e o setor privado. Empresas demandam mão-de-obra, recebem incentivos para contratá-la (inclusive fiscais) e podem investir naquele funcionário que fará sua transição do cárcere para a liberdade empregado.

A principal experiência que conheci nesses últimos anos e o modelo mais eficaz de ressocialização, verificado em baixíssimos percentuais de reincidência, é o empreendido pela Associação de Proteção e Assistência aos Condenados (APAC), entidade privada, com o objetivo de gerir estabelecimentos penais em atenção aos ditames da Lei de Execução Penal e conforme uma metodologia fundamentada em rígida disciplina, “respeito, ordem, trabalho e envolvimento da família do sentenciado”.

Os resultados são estudados há décadas e não há como questionar, nessa perspectiva, o êxito do modelo privado da APAC. Os motivos da resistência enfrentada para expandi-lo ainda me parecem muito nebulosos, passando um pouco pelo corporativismo dos servidores públicos (a APAC não usa mão de obra estatal; não há servidores, policiais, agentes penitenciários, apenas voluntários) até frequentemente pela ignorância do que é a entidade e de como funciona pelos próprios gestores públicos (todos aqueles que listei no tópico 5).

Outra alternativa são os presídios construídos e geridos em regime de cogestão, conforme a Lei das Parcerias Público-Privadas. A principal unidade com esse formato no país é, sem dúvida, o Complexo Penal de Ribeirão das Neves, cuja modulação do contrato de concessão definiu que o Poder Público do Estado de Minas Gerais permanece responsável pela segurança armada de muralhas e externa, enquanto a concessionária incumbe-se de satisfazer indicadores rigorosos de educação, trabalho, saúde, assistência jurídica e psicológica a apenados e familiares.

Sobre o custo de ambos os modelos privados, estima-se que a APAC opere com custo inferior por preso do que aquele que o Estado drena do Erário para permitir rotineiras violações de direitos humanos e massacres como o de Manaus – contudo os estabelecimentos geridos pela APAC, dependente de voluntários, não teria a capacidade de satisfazer toda a demanda de vagas. Por sua vez, as PPPs como a de Ribeirão das Neves cobrariam um custo mais elevado por preso do que o Estado opera, mas não há como comparar o rigor do cumprimento dos direitos do preso, todo o cuidado com a segurança e a responsabilidade compartilhada com a concessionária.

As soluções privadas devem ser postas à mesa e debatidas, inclusive para aperfeiçoá-las e para refutar modelos precários de terceirização como o existente no presídio de Manaus onde ocorreu a tragédia das últimas semanas. O fato é que devemos fazer da crise um momento de reinvenção do maior símbolo de atraso do nosso país. Ou então estamos condenados à barbárie.

crowbanner-1

O post 7 coisas que aprendi trabalhando no sistema prisional brasileiro apareceu primeiro em Spotniks.

04 Jan 20:51

An Uncensored Sex Game's Difficult Journey To Steam

by Nathan Grayson on Steamed, shared by Nathan Grayson to Kotaku

Ladykiller In A Bind—which Heather found to be a bold exploration of sexual experiences and perspectives—is finally coming to Steam on January 9. It’ll be fully uncensored, despite the way Valve usually handles these things. For creator Christine Love, reaching this point wasn’t easy.

Read more...

30 Dec 15:32

The Concourse Young Man Enjoys Phish Concert | Jezebel Becoming Ugly | Gizmodo Aerosmith made more m

by Kinja! on Kinja Roundup, shared by Riley MacLeod to Kotaku
29 Dec 14:04

The Concourse Where The Fuck Are This Girl’s Legs?

by Kinja! on Kinja Roundup, shared by Riley MacLeod to Kotaku
02 Dec 09:27

Geoff Keighley Gives Emotional Speech For Hideo Kojima, Puts Konami On Blast

by Patricia Hernandez

A year ago, Hideo Kojima was supposed to receive a trophy at The Game Awards for Metal Gear Solid V. Due to bullshit from Konami, Kojima couldn’t attend the event. Tonight, things have been set right.

Read more...

26 Nov 17:35

This Week In The Business: Those Old Brick-And-Mortar Blues

by Brendan Sinclair

STAT | 20% - Watch Dogs 2's launch week sales at UK retailers were down 80% compared to the performance of the original Watch Dogs. It was the latest in a string of disappointing UK launches for AAA games this fall.

Read more...

24 Nov 00:06

Nextcloud: an Open-source Dropbox, Google Drive Alternative

by Kristi Progri

File storage services like Dropbox, Google Drive and OneDrive are very popular these days. They automatically sync your files to the cloud and across your various devices, making your data highly accessible and ensuring that it's not easily lost.

They offer a certain amount of free storage, but if you're looking to store most or all of your files online, you'll need to pay for them. Their fees are not particularly high, but still, it would be nice to have a free alternative.

Fortunately, there are alternatives. One of them is Nextcloud, an open-source alternative to Dropbox and the others that you install and maintain on your own server.

Let's take a look at some of the reasons to consider using Nextcloud.

What's Wrong with the Big Players?

It's reasonable to ask why we should bother setting up something on our own server when services like Dropbox and Drive are so easy to use. They're basically plug-and-play, and are supported and maintained by large companies that have a stake in providing a secure and reliable service.

They do have downsides, though. Of course, there are the fees, which are fixed, not tailored to everyone's needs, and could change at any time.

By using them, you're also entrusting your data to companies that don't entirely deserve your trust. They can mess with your data at any time, if they so choose, as highlighted in Apple's terms and conditions:

Apple reserves the right at all times to determine whether Content is appropriate … and may pre-screen, move, refuse, modify and/or remove Content at any time, without prior notice and in its sole discretion …

They could, of course, just shut down. (That doesn't happen often, but it does happen.) They can also get bought out. Remember Sunrise calendar? Exactly what they did with their calendar app when Microsoft bought them.

Taking Back Control

Nextcloud is a cloud software alternative that gives you full control over your data. It's designed for both individuals and organizations with many users. It's a relatively young project, being a fork of the similar ownCloud project, which is also worth checking out and comparing.

Having control of your own data is pretty attractive, but how does Nextcloud stack up against the commercial players in other ways, such as features and security? Let's take a look.

Security & custom two-factor authentication (2FA)

On the security side, Nextcloud provides documentation to explain security best practices. Unsafe or controversial functions are strictly refused, and mandatory code is reviewed by two more reviewers to make sure that everything is bulletproof (or as much as it can get).

Furthermore, the Nextcloud authentication system is two factored. Active sessions can be invalidated through the list, by removing the user in the admin settings or by changing passwords. Admins can enable or disable two-factor authentication for users on the command line.

While other proprietary services like Dropbox offer 2FA as well, Nextcloud allows you to "force" enable or disable 2FA for specific members of the organization. With a little bit of tweaking, you can also create your own 2FA provider, to avoid being locked in with a specific 2FA app. Huge advantage for those concerned with security here.

Encryption

Nextcloud also offers server-side encryption, which is not enabled out of the box (to offer a better user experience for newcomers). Nextcloud servers encrypt remote data, but your local storage operates without encryption by default. It's important to be aware that the encryption does increase the file size by 35%, which isn't necessarily a deal-breaker if you're concerned about security.

Note: Once enabled, server-side encryption cannot be disabled within the admin dashboard. So be sure to back up user encryption keys regularly. If a key is lost, that data cannot be accessed anymore.

Federation Sharing

Another feature Nextcloud offers is Federation Sharing, which mounts file shares from remote Nextcloud servers (or other servers which support it, such as ownCloud-powered servers) to create your own cluster of clouds. Imagine this as Folders in Dropbox or Google Drive you are invited to collaborate and have access to. However, in this case it's using an open protocol, which is compatible with many other providers (such as ownCloud). Mounted Shares will give you direct access to the Folder you are invited to, so your server space won't be used up for your own copy of files.

This allows for decentralized file sharing, no matter where the data is stored, with flexible admin privileges to set individual user permissions. You can use a Federated Cloud ID to share files with fellow Nextclouders based on your username (for example: username@example.com/nextcloud).

Server Information App

With the server information app you can also check the performance of your Nextcloud Server. This can come in handy for troubleshooting or making improvements on your server. The app is part of the Nextcloud installation, so you don't need to install anything manually to use it. It lets you track:

  • CPU load and memory usage
  • number of active users over time
  • number of shares in various categories
  • storage statistics
  • server settings like PHP version, database type and size, memory limits and more.

Continue reading %Nextcloud: an Open-source Dropbox, Google Drive Alternative%

30 Sep 20:20

Using JOINs in MongoDB NoSQL Databases

by Craig Buckler

Using $lookUp with NoSQL

Thanks to Julian Motz for kindly helping to peer review this article.


One of the biggest differences between SQL and NoSQL databases is JOIN. In relational databases, the SQL JOIN clause allows you to combine rows from two or more tables using a common field between them. For example, if you have tables of books and publishers, you can write SQL commands such as:

SELECT book.title, publisher.name
FROM book
LEFT JOIN book.publisher_id ON publisher.id;

In other words, the book table has a publisher_id field which references the id field in the publisher table.

This is practical, since a single publisher could offer thousands of books. If we ever need to update a publisher's details, we can change a single record. Data redundancy is minimized, since we don't need to repeat the publisher information for every book. The technique is known as normalization.

SQL databases offer a range of normalization and constraint features to ensure relationships are maintained.

NoSQL == No JOIN?

Not always …

Document-oriented databases such as MongoDB are designed to store denormalized data. Ideally, there should be no relationship between collections. If the same data is required in two or more documents, it must be repeated.

This can be frustrating, since there are few situations where you never need relational data. Fortunately, MongoDB 3.2 introduces a new $lookup operator which can perform a LEFT-OUTER-JOIN-like operation on two or more collections. But there's a catch …

Continue reading %Using JOINs in MongoDB NoSQL Databases%

20 Sep 11:35

Introducing the Colony Voting Protocol implementation - Part 1! #ethereum #devcon2 https://blog.colony.io/token-weighted-voting-implementation-part-1-72f836b5423b#.r0bkybk6r …

by Colony (@joincolony)
10 Sep 17:00

The Blockchain: An Experiment in Governance Without Power

by Ariel Deschapell
Cryptocurrencies aren't just an experiment in monetary theory, but also a radical experiment in decentralized governance, says Ariel Deschapell.