<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Nathanael Ren on Medium]]></title>
        <description><![CDATA[Stories by Nathanael Ren on Medium]]></description>
        <link>https://medium.com/@nathanaelren?source=rss-778d75015485------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*4yEAm8R5xzMYp80c4fx_Fg.jpeg</url>
            <title>Stories by Nathanael Ren on Medium</title>
            <link>https://medium.com/@nathanaelren?source=rss-778d75015485------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Sun, 06 Dec 2026 19:30:05 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@nathanaelren/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Solving OGB Function Name Prediction Using Data Augmentation and DiffPool Hierarchical Pooling]]></title>
            <link>https://medium.com/stanford-cs224w-fall-2023-course-projects/solving-ogb-function-name-prediction-using-data-augmentation-and-diffpool-hierarchical-pooling-fb20d3a688e1?source=rss-778d75015485------2</link>
            <guid isPermaLink="false">https://medium.com/p/fb20d3a688e1</guid>
            <category><![CDATA[machine-learning]]></category>
            <category><![CDATA[graph-neural-networks]]></category>
            <category><![CDATA[deep-learning]]></category>
            <category><![CDATA[graphsage]]></category>
            <dc:creator><![CDATA[Nathanael Ren]]></dc:creator>
            <pubDate>Thu, 28 Dec 2023 19:41:51 GMT</pubDate>
            <atom:updated>2023-12-28T19:41:51.291Z</atom:updated>
            <content:encoded><![CDATA[<p><em>Stanford CS224W Project by “Nathanael” Yu Ren, Henry Ang, Lucy Zhu</em></p><p>Please also see this <a href="https://drive.google.com/drive/folders/1TP2U8QE_WOrmvdLAUnAS09n-2t-Wp9Z_">Google Drive</a> for all Colab files or <a href="https://github.com/rendude/DiffPool_graphSAGE_CodeBERT_Implementation">GitHub</a></p><h3>Introduction and Motivation</h3><h4>The problem</h4><p>In many real-world text-based applications, the ability to condense longer forms of text blocks into shorter and higher-level topologies is critical in being able to understand user-base trends and customer needs. For example, in the contact center space, the ability to summarize call transcripts into single-topic phrases allows business insight teams to understand the distribution of urgent customer concerns. This is a multi-million dollar opportunity that has not yet seen a widely accepted solution.</p><p>Clustering technology using word embeddings has demonstrated poor performance due to the high dimensionality of word embeddings, the presence of many outliers, and the difficulty in determining right seeding given the wide range of conversations. Typically such clustering techniques yield a precision rate of 10 to 30%. Other methods of using LLMs like GPT4 to zero-shot question-and-answer tag predictions generate too many isolated tags at a heavy price tag, which then requires a laborious manual process to cluster and review.</p><p>In this blog, we will talk about our experimentations with graph augmentation and hierarchical pooling to solve text condensation. The goal is to more accurately predict the final short-phrase topic tag of the paragraph text.</p><h4>Novelty</h4><p>DiffPool and GNNs at large have not been explored as potential methods for text summarization. However, when humans are asked to summarize a chunk of text with one phrase, the implicit exercise we do in our minds is what word most likely represents the commonality among all of the words. One way to model this is what node in a connected graph captures and can represent the subgraph of nearby nodes. DiffPool is built for this purpose and is worthwhile to pursue for the task.</p><p>In addition, as you’ll see in the following section, we picked a graph-level OGB code summarization task where DiffPool has yet to be applied by the participants in the leaderboard. Furthermore, while exploring ways to outperform models on the leaderboard, we went above and beyond DiffPool implementation and tried several novel techniques to provide additional enhancements:</p><ul><li>CodeBERT embedding as the input into GNN in the pre-processing step</li><li>RNN LSTM layers as post-processing</li><li>Depth-biased pooling instead of global pooling</li></ul><p>All listed above will be explored in further detail below.</p><h3>Application Domain</h3><h4>Dataset</h4><p>For modeling, we chose to use the OGB graph-level prediction dataset <a href="https://ogb.stanford.edu/docs/leader_graphprop/#ogbg-code2">ogbg-code2</a>, which is a collection of 450k Python function definitions compiled from GitHub CodeSearchNet repositories. It is split into a training, validation, and test set where the training has approximately 410k samples, the validation has around 20k samples, and the test has around 20k samples. Each sample is a graph built from an AST hierarchy tree. Every node of the graph has 2-dimensional features where each dimension is an ID that maps to the raw <a href="https://docs.google.com/spreadsheets/d/1AxRRfu_Vzecs9b3iQS2HQ4lSumos7wn0/edit?usp=sharing&amp;ouid=116932977220188674139&amp;rtpof=true&amp;sd=true">code type</a> (e.g. for, while, list) and the raw <a href="https://docs.google.com/spreadsheets/d/1w_w6xvFRpmaGauB1DxnuNtpiCA95GaI6/edit?usp=sharing&amp;ouid=116932977220188674139&amp;rtpof=true&amp;sd=true">code attribute</a> (e.g. variable names). The nodes as input are sorted in DFS traversal order. The true labels y are the indices of the words that make up the method names.</p><p>We picked this dataset because it offers several advantages for this project. First, DiffPool has yet to be applied to such a heterogeneous graph. Secondly, ogbg-code2 already converted all code text into directed AST graphs and is closest to a summarization task among the OGB datasets. These graphs have heterogeneous edges (e.g. conditional, else) and are in a ready-to-use format, thereby reducing the scope of this project to be manageable. Thirdly, all submissions on the leaderboard have publications, so we can compare our methodology outcome.</p><h4>Task and Metric</h4><p>The task is often referred to as “code summarization,” whereby the model takes the code AST graph as input and predicts up to 5 words that make up the method name for each graph. The words could be 1 of 5000 in the vocab list. This is a graph-level prediction task where, after all node embeddings are pooled into a prediction head, we perform a classification task that splits the prediction head into 5 outputs, each being the softmax probability the model assigns to the word at its index. Cross-entropy loss is used. An evaluator then calculates the F1 score for the accuracy of the model’s predicted method name.</p><p>While this is not exactly paragraph-form text condensation, there are lots of similarities — code summarization necessitates a form of text coarsening where code text is condensed. In fact, code summarization is harder because we have to predict the word sequence with just the code structure, which is often unrelated to the method naming. Solving the challenge for method name prediction will yield learnings that are generalizable for solving text summarization in general.</p><h3>DiffPool Modeling</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*lImNnn0epCzchMDn7o1ZZw.png" /></figure><p>We created this illustration to explain how messaging and aggregation actually worked in our implementation.</p><p>The idea for DiffPool is that at each layer, GraphSAGE or another GNN model is used to compute the node embeddings and then <strong>S</strong> coarsens these embeddings into fewer cluster nodes for the next layer. This process repeats until the entire graph is condensed into one node embedding that then is used for classification at the graph level (i.e. method name prediction). The model will have a differentiable assignment matrix that learns the clusters of higher hierarchy.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*qwd-_JzJbRhJOCo2icbyAw.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/502/0*xjDr_T5gZuIXeCjy" /></figure><p>Here are code snippets for defining the DiffPool layers. Each DiffPool layer contains two configurable GNNs, generating node embeddings and assignment matrices respectively. They are subsequently fed into the DiffPool operator to generate the pooled nodes and their adjacency matrix.</p><pre>class DiffPool(torch.nn.Module):<br>   def __init__(self, gnn_embed, gnn_pool, number_of_nodes_out):<br>       super(DiffPool, self).__init__()<br>       self.gnn_embed = gnn_embed<br>       self.gnn_pool = gnn_pool<br>       self.number_of_nodes_out = number_of_nodes_out<br><br>   def forward(self, x, adj, mask=None):<br>       # Compute embeddings and assignment matrix with GNNs.<br>       z = self.gnn_embed(x, adj)<br>       s = self.gnn_pool(x, adj)<br><br>       # Use the DiffPool operator to get pooled graph.<br>       x, adj, l1, e1 = dense_diff_pool(z, adj, s, mask)<br><br>       return x, adj</pre><pre># Define the DiffPool layers<br>self.diff_pool_layers = torch.nn.ModuleList()<br>for number_of_nodes_out, gcn_layer_num in diff_pool_node_number_list:<br>   gnn_embed = GCN(input_dim=emb_dim, hidden_dim=emb_dim, output_dim=emb_dim, num_layers=gcn_layer_num, dropout=drop_ratio)<br>   gnn_pool = GCN(input_dim=emb_dim, hidden_dim=emb_dim, output_dim=number_of_nodes_out, num_layers=gcn_layer_num, dropout=drop_ratio)<br>   diff_pool_layer = DiffPool(gnn_embed=gnn_embed, gnn_pool=gnn_pool, number_of_nodes_out=number_of_nodes_out)<br>   self.diff_pool_layers.append(diff_pool_layer)</pre><h4>Advantages of using DiffPool on AST</h4><p>One limitation of GCN, GraphSage, and even GCN + virtual node is that they are flat when pooling for graph-level prediction. Flat hierarchy loses structural information. Oftentimes in text, chunks of text that are close to each other are related in their topic and can be condensed into one subtopic phrase, which themselves can further condense to higher-level abstractions — think outlines. An architecture like DiffPool that can distinguish the different hierarchies should have an advantage [7].</p><p>As previously mentioned, LLM-based models and clustering algorithms have underperformed. The Abstract Syntax Tree (AST)’s hierarchical structure of ogbg-code2 has unique properties that make hierarchical pool methods such as DiffPool likely to outperform classical GNNs. Logical components of a function are captured by distinct subtrees of the AST. Nodes closer to the root represent higher-level abstractions in the function, while nodes closer to leaves represent finer granular operations. Additionally, we are interested in generating different levels of coarseness when summarizing the AST, which requires hierarchical pooling.</p><h3>Insights and results</h3><h4><strong>Our Results vs OGBG Leaderboard</strong></h4><p>In total, 32 experiments were conducted, each taking 6 hours to code and train on a V100 GPU. We were initially puzzled at why given the same models, we could not replicate the results seen on the <a href="https://ogb.stanford.edu/docs/leader_graphprop/#ogbg-code2">OGBG-code2 leaderboard</a>. For example, we only got to at most 12.8% with GCNs, and yet the leaderboard claims 15%. The difference is more pronounced when looking at GAT (our 12.8% vs their 15.7%). What’s stranger is that when we set our hyperparameters to exactly to the GCN linked code, our results were 4% less on the GCN model (our 11.1% vs their 15.0%). Same for all models tried, GCN, GIN, GAT. After much exploration and review of our code, we realize that the difference lies in the hypermeter tuning. The leaderboard models were able to our more computing resources finding the optimal. Given that we have shown hyperparameters made a huge difference in our ablation studies, we guess that on average there is 3% of performance left on the table if we had all of the training resources in hand. However, given each experiment required a V100 GPU 6 hours to run, what we did was quite expensive already for a small team. It is a shame though, because it would have meant that the methodology our team tried could have achieved as high as 18% (our 15.3%+3%), well within the top 5 of the leaderboard.</p><h4>DiffPool</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*mnFptgOp5A42YUxB" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1020/1*Zm6Hx40nVHDAxL0HdPt2Kw.png" /></figure><p>We went through a few iterations of DiffPool model implementations. In the initial implementation, in each DiffPool layer, we used 2 GCNs with a fixed number of layers to compute the node embeddings and assignment matrix. With some initial experimentations, we realized that the reduction in the number of nodes in each DiffPool layer meant the number of GCN layers may also need to be reduced to prevent over-smoothing. For example, if the 500 nodes of the original graph are pooled into 32 nodes, then the GCN layers needed to produce meaning for embeddings would need to decrease as well. The config for the pooling layers is presented as a sequence of (number of nodes after pooling, number of layers of GNN for the current DiffPool layer). For example, [(128, 5), (32,3)] indicates there are 2 DiffPool layers where the first pools the graph into 128 nodes using 5-layer GNNs, and the second pools the graph into 32 nodes using 3-layer GNNs.</p><p>During initial training, we also found that the GPU often encountered out-of-memory issues with larger batch sizes. We realized that the problem lies with the dense adjacency matrix required by the DiffPool operator. We modified the implementation to impose a max number of nodes to limit the adjacency matrix’s size. With the majority of the graphs having less than 500 nodes, we found that using 1500 as the max number of nodes prevented GPU OOMs with little impact on the performance.</p><p>The hyperparameter tuning process was difficult for the DiffPool model mainly due to the many floating pieces in the config of the DiffPool pooling layers. Combined with other hyperparameters choices like GNN type, learning rate, and batch size, it was difficult to sufficiently explore the space of hyperparameters. With limited resources, we mainly focused on exploring the effect of having different pooling configurations and found that more pooling layers and deeper GNNs degraded the performance. We theorized that the resulting increased complexity of the model from more pooling layers and deeper GNNs resulted in more overfitting. Even with only a single layer of DiffPool with moderate GNN depth, the F1 scores during training were significantly higher than those of testing and validation.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*PFOApy8PjhcguX1w" /></figure><p>The DiffPool experiments resulted in slightly higher performance than the baseline GCN models. The hierarchical pooling provided some performance improvements for the task. On the other hand, the complexity of the model makes training hard and prone to overfitting.</p><h4>Ablation studies</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*qRYuMq4qbr-nGMHf" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*5o1RchHBLaHsW3CL" /></figure><p>For our ablation studies, we started with the most basic GNN model and incrementally added additional complexity to isolate the effect of each.</p><p><em>Baseline GCN</em></p><p>The starting point was a 3-layer GCN that summed all output node embeddings into a single prediction head. Both pre-and post-processing steps were simple linear transformations. This exercise not only established a baseline of 5.8% F1 score but also helped us figure out how to build a GNN training pipeline that works end-to-end on this graph-level classification task.</p><p><em>Hypermeter Tuning</em></p><p>After establishing a baseline, we optimized hyperparameters before trying more complex model changes. Changing hyperparameters yielded three insights:</p><ol><li><em>Oversmoothing</em><strong>:</strong> Fewer layers yielded better results. 3 layers performed universally better than 5 layers. This was true across all of the different GNN models. This result suggests to us that over-smoothing is a reality for these graphs because they are on average only 125 nodes.</li><li><em>Lower dropout</em>: Starting with a 0.5 dropout rate, we gradually lowered dropout rates and found that lowering the dropout rate induced more overfitting but also led to higher test-set F1 scores. It could be that the preservation of information outweighs overfitting for the validation and test sets.</li><li><em>Learning adjustments</em><strong>: </strong>Decreasing the learning rate from 0.01 and a factor of 10 and weight decay by a factor of 1000x improved training stability.</li></ol><p><em>AST Encoder Pre-Processing and MLP Post-Processing</em></p><p>Given GCN’s poor performance, we hypothesized that i) a linear transformation of input features was not expressive enough and ii) because the classification task involves global pooling all nodes into a single graph-level prediction head and then splitting it into 5 predictions each of which has thousands of classes, post-processing needs be very sensitive to minute differences in the prediction head.</p><p>Therefore, we added a basic AST encoder as a pre-processing step. The AST encoder converts each input feature — node type id, node attribute id, and node depth — into randomly initialized embeddings and then sums them together.</p><pre>class ASTNodeEncoder(torch.nn.Module):<br>    def __init__(self, emb_dim, num_nodetypes, num_nodeattributes, max_depth):<br>        super(ASTNodeEncoder, self).__init__()<br>        self.max_depth = max_depth<br>        self.type_encoder = torch.nn.Embedding(num_nodetypes, emb_dim)<br>        self.attribute_encoder = torch.nn.Embedding(num_nodeattributes, emb_dim)<br>        self.depth_encoder = torch.nn.Embedding(self.max_depth + 1, emb_dim)<br><br>    def forward(self, x, depth):<br>        depth[depth &gt; self.max_depth] = self.max_depth<br>        return self.type_encoder(x[:,0]) + self.attribute_encoder(x[:,1]) + self.depth_encoder(depth)</pre><p>AST encoding creates a learnable embedding for each node type and attribute, thereby doubling GCN performance to an F1 score of 12.87%.</p><p>Following this success, we had high hopes for what more robust post-processing could do. However, our first attempt with a 5-layer MLP significantly decreased performance. We hypothesized that MLP did not work well on this task because word sequence mattered for method name prediction. Modeling changes were needed as covered below.</p><p><em>GNN Expressiveness</em></p><p>Once we noticed a diminished margin of return from non-modeling changes, we carried over those learnings and applied them to more expressive models, namely GraphSAGE [3], GAT [4] (with 3 attention heads), GIN [5], DiffPool, DiffPool + RNN, and GraphSAGE + biased depth pooling. Overall, we noticed that the expressiveness of the models did not correlate one-to-one with gains in performance. In fact, GIN, in theory the most expressive GNN, relatively performed poorer. Several data points also point in this direction. For example, diffPool and extra convolution layers all brought comparable results if not worsened the result. We think that the reason behind this surprising finding is that model expressiveness is only one of the challenges in this classification task. The code2 AST graphs are relatively small in size (~100 nodes) and yet their classification size can be one of 5000 vocabularies. The key challenge therefore might be unrelated to how well we capture code structure but instead the relationship between words in the name. The best model in the ablation studies was GraphSAGE with depth-biased pooling performed best at 15.34% F1 score. We then took this model and tried it with a number of augmentation methods to boost performance.</p><p><em>Depth-biased Pooling</em></p><p>Because the graphs in the dataset are Syntax Trees, we hypothesized that within a syntax tree, the embedding of the nodes that have lower depth / closer to the root node should have higher importance because they represent higher-level constructs in a function. When pooling the node embeddings into the graph embedding, we gave nodes exponentially lower weights with respect to the depth of the node while preserving order invariance. Because the node depth is a node feature, the weight given to a node is the same regardless of node ordering.</p><p>Empirically, this change provided non-trivial improvement to the model performance, and the best-performing models in our experiments all incorporated this pooling mechanism.</p><p><em>RNN Prediction Head</em></p><p>One observation we made about the model’s predictions is that they often do not capture the sequential nature of function names well. To make the prediction sequence better learn the sequencing of words, we decided to add recurrent layers to the prediction head. We added LSTM layers that take in the graph embeddings to generate the prediction sequence, but it degraded the performance of the model. Additional techniques like teacher forcing didn’t yield improvements either.</p><h3>Augmentation studies</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*gMVfQJvwLZB4AaaL" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*miI6raVi8RqYndMW" /></figure><p><em>CodeBERT Embeddings</em></p><p>Witnessing that a basic AST encoding pre-processing step yielded almost 4% boost in F1 score, we wanted to invest further in more complex node augmentation techniques. One of the weaknesses of the AST encoder is that it is a simple shallow embedding of the ID, which loses all semantic information. CodeBERT is a pre-trained multimodal lingual model for programming languages [6]. It was pre-trained on 6 different languages, one of them being Python which is vital to our project as the ogbg-code2 dataset samples are written in Python. Our objective with incorporating CodeBERT is to use the token embeddings output by this model as part of the node embedding initialization in our model. We created a new class called SemanticNodeEncoder. Like the AST encoder, it leverages 3 embedding tables — self.type_node, self.attribute_encode, self_depth_encoder. Except, at initialization, instead of randomized features, SemanticNodeEncoder calls a get_embedding function to essentially run all of the node type and node attribute strings through CoderBert to yield an embedding that carries semantic meaning in the embedding space.</p><pre>class SemanticNodeEncoder(torch.nn.Module):<br>    &#39;&#39;&#39;<br>    Use CodeBERT to convert node type strings and node attributes strings into embeddings.<br>    Depth is not used in this embedding.<br>        Input:<br>            emb_dim: default node feature of N X D<br>            node_types: list of node type strings [98 type_string]<br>            node_attributes: list of node attribute strings [10029 attribute_string]<br>            depth: The depth of the node in the AST.<br>        Output:<br>            BERTCode-based embedding, which sums the embeddings of the node type<br>            and node attribute strings. Dim: N x 768<br>    &#39;&#39;&#39;<br>    def __init__(self, codeBert, tokenizer, emb_dim, node_type_mapping, node_attributes_mapping):<br>        super(SemanticNodeEncoder, self).__init__()<br>        ...<br>        ...<br>        self.type_encoder = torch.nn.Embedding(len(node_type_mapping), emb_dim)<br>        self.attribute_encoder = torch.nn.Embedding(len(node_attributes_mapping), emb_dim)<br>        self.depth_encoder = torch.nn.Embedding(self.max_depth+1, emb_dim)<br><br>        self.type_encoder.weight = torch.nn.Parameter(self.get_embedding(node_type_mapping))<br>        #self.attribute_encoder.weight = torch.nn.Parameter(self.get_embedding(node_attributes_mapping))<br><br>    def get_embedding(self, mapping):<br>        &#39;&#39;&#39;<br>        Input:<br>            mapping: Either list of node type strings [98 type_string] or list of node attribute strings [10029 attribute_string]<br>        Output:<br>            BERTCode-based embedding of node attribute strings. Dim: N x 768<br>        &#39;&#39;&#39;<br>        ...<br>        ...<br>        # codeBert steps taken to transform strings into embeddings<br>        tokens = self.tokenizer.tokenize(feature_string)<br>        tokens_ids = self.tokenizer.convert_tokens_to_ids(tokens)<br>        tokens_tensor = torch.tensor(tokens_ids).to(device)[None,:]<br>        node_embedding = self.codeBert(tokens_tensor)[0].view(tokens_tensor.shape[1], -1)<br>        node_embedding = node_embedding.sum(dim=0, keepdim=True) # sum embeddings if &gt;1 word in the feature string<br>        ...<br>        ...</pre><p>The resulting node_encoder of SemanticNodeEncoder class is then passed into a GNN model of our own choosing to encode the node features. This method almost always outperformed the existing model. What we noticed particularly is an improvement in training set accuracy that reached as high as 52%, albeit the overfitting did not impact the testing set as largely. In addition, between node type, node attribute or an aggregation of the two, node attribute was slightly higher than node type and almost 1.5% higher than if we were to sum both together. We believe this because while every function has the same set of operators (e.g. for, while), they have different node attributes (e.g. variable names) that are more closely related to words chosen for the method name.</p><h3>Concluding Lessons and Future Work</h3><p>As mentioned above, given that extensive and expensive hyperparameter tuning can make 3% of difference for the same models, the enhancements we have made in this project would mean an equivalent performance boost that is meaningful (F1 18.2%) and places our approach well within top 5 of the leaderboard. While DiffPool did not produce the step function improvement we had hoped, it was among the top performers overall and if given an actual text summarization dataset, its expressive power would have been more useful — the lack of semantic connection between code text and method name made expressiveness less useful; in real paragraph text, the connection is much stronger if not a word directly chosen from the text.</p><p>It was a really fun and informative experience to work on the project. For the future, we would love to:</p><ol><li>Use a transformer-based decoder to generate the target sequence of words. In our experiments, we found that LSTM-based RNN did not perform well for the task. With the self-attention of the transformer, it will likely outperform RNNs and produce more coherent sequences of function name predictions.</li><li>Further tuning of hyperparameters in the model to reduce overfitting and improve the overall performance.</li><li>Explore heterogeneous architectures like RGCN. In our experiments, the node types are embedded as node features. The different relationships between node types may be better learned through a heterogeneous model.</li></ol><h3>References</h3><p>[1] Alexandre Duval and Fragkiskos Malliaros. Higher-order clustering and pooling for graph neural networks. Conference on Information and Knowledge Management, 2022.</p><p>[2] Rex Ying, Jiaxuan You, Christopher Morris, Xiang Ren, William Hamilton, and Jure Leskovec. Hierarchical graph representation learning with differentiable pooling. Neural Information Pro-cessing Systems, 2018.</p><p>[3] William L. Hamilton, Rex Ying, and Jure Leskovec. Inductive representation learning on large graphs, 2018. <a href="https://arxiv.org/abs/1706.02216">https://arxiv.org/abs/1706.02216</a></p><p>[4] Petar Veliˇckovi ́c, Guillem Cucurull, Arantxa Casanova, Adriana Romero, Pietro Liò, and Yoshua Bengio. Graph attention networks, 2018. <a href="https://arxiv.org/abs/1710.10903">https://arxiv.org/abs/1710.10903</a></p><p>[5] Keyulu Xu, Weihua Hu, Jure Leskovec, and Stefanie Jegelka. How powerful are graph neural networks?, 2019. <a href="https://arxiv.org/abs/1810.00826">https://arxiv.org/abs/1810.00826</a></p><p>[6] Zhangyin Feng, Daya Guo, Duyu Tang, Nan Duan, Xiaocheng Feng, Ming Gong, Linjun Shou, Bing Qin, Ting Liu, Daxin Jiang, and Ming Zhou. Codebert: A pre-trained model for programming and natural languages, 2020. <a href="https://arxiv.org/abs/2002.08155">https://arxiv.org/abs/2002.08155</a></p><p>[7] Rex Ying, Jiaxuan You, Christopher Morris, Xiang Ren, William L. Hamilton, and Jure Leskovec. Hierarchical graph representation learning with differentiable pooling, 2019. <a href="https://arxiv.org/pdf/1806.08804.pdf">https://arxiv.org/pdf/1806.08804</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=fb20d3a688e1" width="1" height="1" alt=""><hr><p><a href="https://medium.com/stanford-cs224w-fall-2023-course-projects/solving-ogb-function-name-prediction-using-data-augmentation-and-diffpool-hierarchical-pooling-fb20d3a688e1">Solving OGB Function Name Prediction Using Data Augmentation and DiffPool Hierarchical Pooling</a> was originally published in <a href="https://medium.com/stanford-cs224w-fall-2023-course-projects">Stanford CS224W Fall 2023 Course Projects</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[How to Ship a Product and Focus on the Right Priorities]]></title>
            <link>https://nathanaelren.medium.com/how-to-ship-a-product-and-find-10x-opportunities-2e679a2a0999?source=rss-778d75015485------2</link>
            <guid isPermaLink="false">https://medium.com/p/2e679a2a0999</guid>
            <category><![CDATA[leadership]]></category>
            <category><![CDATA[technology]]></category>
            <category><![CDATA[artificial-intelligence]]></category>
            <dc:creator><![CDATA[Nathanael Ren]]></dc:creator>
            <pubDate>Tue, 13 Dec 2022 21:37:56 GMT</pubDate>
            <atom:updated>2023-03-15T08:49:21.500Z</atom:updated>
            <content:encoded><![CDATA[<p>Over the years, working with talented engineering managers and product managers has helped me distill down a few rules of thumb about how to ship builds and find 10x improvements. Whether it’s building an internal tool or consumer facing feature, here are a few tips I learned the hard way after many trials and errors.</p><h3>Start with a strong vision or missional statement</h3><p>A vision for where your team could ultimately produce, however far distant that vision might be, is an very important exercise that should not be skipped. <strong>Making something great takes a whole team of talented people singularly focused on the task for a long time. </strong>So at a high level, a great inspiring vision can greatly help inspire the team to do their best work and get buy-ins from other teams.</p><p>In practice, coming up with the mission statement pushes you to ask many necessary questions.</p><ol><li><strong>Stakeholder needs</strong>: To the stakeholders, what is the job to be done for them. What is the ideal scenario?</li><li><strong>Believability</strong>: How much of the ideal is pure fantasy vs inspiration that one can reasonably believe in?</li><li><strong>Scope</strong>: How broad is the scope of this vision? Too broad of a vision could potentially derail your focus and produce something that does a lot of things, but none great.</li><li><strong>Ecosystem benefits</strong>: Last but not least, how much of that ideal aligns with the ecosystem that the company is trying to deliver?</li></ol><p>Answering these questions is harder than it looks but the end result is that your team will have a measuring stick to know if you are spending time on the right passion.</p><h3>Understanding the job-to-be-done</h3><p>There is a saying that people don’t want to buy a quarter inch drill, they want a hole in the wall. In everything I built, whether it be an internal tool or a consumer facing funnel, I found that understanding the actual problem to be solved can mean the difference between spending a quarter on an overkill feature vs. a simple 5-story-point feature that effectively solves the same problem. <strong>Given a team of talented EMs and SWEs, you can solve almost anything but trouble comes if you are spent weeks solving the wrong solution.</strong> You’ll stretch the team thin trying to have the cake and eat it too, without shipping a product that is best in the market. I always tell myself to checkoff this list to make sure I am thinking corectly about the problem space:</p><ol><li><strong>Keep asking whys: </strong>Ask users of the feature the 5 whys — i.e. start with why they want a feature and then ask a series of whys to their answers to gather a complete picture of the underlying motivation.</li><li><strong>A Measure for PMF: </strong>Ask the question how sad would the user be if you took away this feature. Studies have shown that if 40% of users you ask answer with “very disappointed,” there is significant product market fit and likelihood of viral adoption. This will help you understand what is a nice to have vs what will solve a pain point.</li><li><strong>Don’t jump to solutioning:</strong> Ask your engineers and designers what is the best. Empower them to do what they are hired to do. They will surprise you.</li></ol><h3>Be metrics driven and create an operating model</h3><p>There are three different types of metrics to keep track of, four if you are in ML. I divide them into two buckets</p><p><strong>Online metrics</strong>: These are the metrics that are directly tied to the business outcomes.</p><ul><li>Leading metrics and North star — They are the funnel metrics that lead to a north star metric. They are often the KPIs in your OKRs.</li><li>Counter metrics — these are metrics you have to monitor to make sure that by optimizing the North Star metric, you don’t make other parts of the ecosystem worse. They often also capture scenarios where things can be gamed. For example, if your north star metric is amount of screen time per day, a counter metric might be # sessions that had an active engagement within 30 mins in case people just left the site open. Or it could be number of core pages/profiles visited per day, just in case people are spending time on parts of the app that the company want to deprioritize.</li><li>Guardrail metrics — these are metrics help you sanity check against the lead metrics in an A/B test. For example, if a test should</li></ul><p><strong>Offline metrics: </strong>This is very important for ML products. These are metrics that measure the goodness of ML models at their predictions. Precision, recall, F1, AUC, ROC and a confusion matrix are often monitored.</p><p><strong>Forecast your online metrics</strong></p><p>Not everyone likes excel spreadsheets but I find that having an operating model (i.e. a means of forecasting metrics) is essential to knowing the right priorities.</p><blockquote><strong>Without objective metric forecasting, prioritization exercises tend to be based on gut-feelings and a merry-go-round of my-word-against-your-word deadlocks.</strong></blockquote><p>Structure the model such that the columns are months in a year and the rows are all of the metrics that are important to the project. These metrics may be online metrics (e.g. metrics belonging to an UX funnel) or offline metrics (e.g. number of labelers, number of unlabeled samples and model F1 scores). The idea is that you want to put down variables that are intertwined such that tweaking one metric impacts another. <strong>They should all add up or multiple together to produce the north star metric at the bottom </strong>— the last row is the OKR result you are trying to hit in six months (e.g. revenue, CAC, AUC, perfect labels delivered etc). The metrics above should multiple together to impact this bottomline metric.</p><p>Once you set up this operating model,</p><ol><li><strong>10x vs 1.2x</strong>: When you have this operating model, you can play around with the numbers and see which levers move the needle the most and de-risk everything else. This is true especially if you were to put down an almost impossible upper bound on a metric that you thought was important and notice that it only 1.2x the bottomline down the road. Oppositely, the operating model will show you where the 10x opportunities are and guide you on hard KPIs for next quarters’ OKRs.</li><li><strong>Robust reporting structure</strong>: An operating model requires many metrics updated in real time. So it forces the team leader to be data centric as well as provides visibility across the organization.</li><li><strong>Objective metrics: </strong>In a meeting where buy-ins are needed and different teammates have different arguments about priority, it is a very potent argument to be able to show that maxing out a metric will not move the needle much. It is very objective and hard to ignore.</li></ol><h3>Be technical</h3><p>I did production level code for years and so I may be biased here but being technical has helped me a number of times to ship faster and better. I wasn’t the smartest engineer compared to our ML engineers but being able to understand the technical difficulties of a feature/pipeline/model and how to estimate its impact vs effort tradeoff will help your team avoid derailment to the wrong focus or help your team jump on the right priorities. As a team leader, your role is ultimately not to come up with the solution. <strong>In fact, empower the technologists to do what they do best but being technical will help you guide the discussion and avoid spreading your team thin chasing after difficult solutions that don’t move the needle much. </strong>If you enjoy being on the technical side, I recommend:</p><ol><li><strong>Weekly publication reviews: </strong>Set up a weekly publication review or latest tech review with the engineers where they can discuss one new research publication, release, or API that may be relevant to your project.</li><li><strong>Help your ML scientists prioritize:</strong> As the team leader, you know the rationale behind certain OKRs that are motivated by things outside of technical feasibility (e.g. business case, client needs, revenue potential, etc). These inputs are often outside the scope of an engineer’s responsibility but very helpful input while deciding which solution to pursue. In fact, challenge your EMs on the paths they decided to go on. Particularly focus on alternative paths that may be blindspots. Sometimes, not knowing the conventional wisdom on a problem may be a good thing.</li></ol><h3>Get buy-in and resolve conflicts for your team</h3><blockquote><strong>Everyone has a different objective and different priorities. Getting alignment and resolving conflicts are often the bottlenecks in shipping.</strong></blockquote><p>It doesn’t matter what the title is. Leaders, the higher the the title, the more they realize that persuading different teams toward a vision is better than strong arming because, over time, top-down leadership styles tend to introduce blindspots and less motivated teams.</p><p><strong>What I found the most effective has been to tailor the message to the audience I am trying to convince while staying on message.</strong> The way to communicate to engineers, who may care about technical feasibility, is very different from the way to communicate to the operational team who care about manual workload. They may not realize that they are tradeoffs that could be made that will satisfy both camps. So centering the conversation around gains to their objective and lessening to their concerns will make a difference.</p><h3>Conclusion</h3><p>Shipping a product on time and consistently yielding better results are an art than a science. Here I highlight a few of my must haves — strong vision, knowing job-to-be-done, being metrics driven, being technical, and getting buy-ins. If you like what you read, let me know in the comments what has made a difference for you and your team!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=2e679a2a0999" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Death, taxes and competition]]></title>
            <link>https://nathanaelren.medium.com/death-taxes-and-competition-c2c9d8974234?source=rss-778d75015485------2</link>
            <guid isPermaLink="false">https://medium.com/p/c2c9d8974234</guid>
            <dc:creator><![CDATA[Nathanael Ren]]></dc:creator>
            <pubDate>Sun, 30 Oct 2022 20:40:10 GMT</pubDate>
            <atom:updated>2022-10-30T20:41:44.931Z</atom:updated>
            <content:encoded><![CDATA[<p>An argument against being in stealth-mode and being afraid of competition</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*75EWJWPJyEybf88H.jpeg" /></figure><p>Competition is often among the first things a skeptic will argue against your startup idea or strategy. I cannot describe how many times in the early years I would beat myself up on days when a tech giant just announced a relevant initiative or a competitor got more funding / deal. It felt like someone punched me in the stomach every time. I’m telling you now, don’t feel that way.</p><p>There are times when you should absolutely be worried about competition. For example, the day iPhone, Tesla model S, Netflix DVDs entered the market, their competitors’ management teams should have immediately recognized the threat and made drastically changes to compete instead of protecting their core businesses and bleed slowly (did you know that Blockbuster actually refused to buy Netflix at $50MM when the offer was made?) But most of the time, competition will not be the reason why you will fail and should not be a factor that keeps you up at night. I will first discuss the scenarios when you should be not worried about competition and then follow up in the next post on when you should.</p><h3>Having lots of competition is a given</h3><p>An exec team will debate often on what areas the company should invest in. The inclination is to expand into an area with minimum competition because of the first mover advantage or degree of ease. But in my experience, this argument has two setbacks.</p><blockquote><strong><em>First, anything worth money will attract more competition than you can imagine at a speed quicker than you can imagine.</em></strong></blockquote><p>I have personally experienced this with a product where we got to the market first and it did well for about 4 months only to see a dozen similar offering springing up everywhere, some more sophisticated.</p><p>The misnomer about moving in a direction of little competition is often grounded in examples like Google, Facebook, Uber etc where winner takes all. However, take a look at the earlier decade of these companies and you will find that most of them were second if not third movers with a minefield of competition. They just happen to be the best, and during those years their formula created a reinforcing flywheel effect that made them stronger.</p><h3>Second movers are often the winners: make a play on price, quality or an unmet-need</h3><p>Second, movers in a space are often the winners.</p><blockquote><strong><em>This is because, first and foremost, the market has been proven and you removed the risk of pursuing a non-market.</em></strong></blockquote><p>You can very easily convince yourself that there is a billion dollar opportunity that no one else is capturing that you alone can for XYZ reasons. When you hear yourself thinking this way, be very very careful, especially if your strategy involves a significant detour from existing consumer behavior. Unless you have true innovation that shortcuts an existing pain point of life by a <em>noticeable</em> amount (e.g. a new material, an app on a new platform, a new chip, a new battery, a new drug etc) — typically in the basic sciences field when there are a bunch of PhDs on your team — what you typically find is that the market doesn’t exist because i) it’s actually not solving a problem people care about; ii) the problem has already been solved, just not in the manner you’d like iii) or no one can yet deliver the sci-fi solution at a reasonable cost and legally (e.g. single drop blood tests or an iphone-like device when the world is still operating on Windows 98).</p><p>By being a later mover, you know there is demand for a consumer behavior and you can see the strength and weaknesses of existing players. The focus then should be how can you make a play on price, quality at similar prices, or an unmet need feature that people actually care about. In fact, it is an incredibly important exercise to jot down how you’re cheaper, higher quality at the same price, or addressing an unmet need that’s worth money. Print those reasons out on a poster and hang them up in your office as a north star so it’s a constant reminder as you build your product.</p><p>Going back to the examples of Google, Apple’s iPhone, Amazon, Uber, etc, I would argue that the $BB market already existed for each. The consumer behavior very well defined.</p><blockquote><em>They each made a play on </em><strong><em>price, quality at the same price or a feature on an unmet need that people will pay for</em></strong><em>.</em></blockquote><p>For example, taxi’s were around for decades. Uber just figured out that they could provide cheaper ride with a democratized driver force and that consumers have an unmet need of wanting to summon a taxi at will on their time and their location. In fact, often when thinking about areas to innovate in, it’s much healthier to take an existing behavior that consumers already do and think in what way can you help them do that thing cheaper or at 2x quality but similar price rather than think in a vacuum about a net new consumer behavior that you can foster with your product.</p><blockquote><em>IF your strategy involves something along the lines of “if my product existed, people will start doing XYZ that they currently just aren’t paying to do because they haven’t discovered this new joy in life yet” — be careful!! Even if successful, and that’s a </em>big if,<em> these are often fads rather than anything sustaining.</em></blockquote><h3>It’s not about when, it’s about who’s best</h3><p>It’s not about when you enter the game, it’s about who is the best. The incumbents have money, marketing, and scale but they are probably the slowest moving creatures ever devised by mankind. They often act like a frog in a pot of water that’s slowly boiling and don’t move until analysts are screaming at their boards. In fact, examples of this are everywhere — Tesla vs Benz, Netflix vs Blockbuster, Redhat vs Microsoft, iPhone vs Blackberry.</p><blockquote><em>So, the question to ask is not how far ahead are they, the question to ask are </em><strong><em>how are you the best and in what niche area gets you the best status the quickest.</em></strong></blockquote><p>So long as you are the best in a niche, you will grow that niche, have money from that niche, expand to adjacents and slowly take over. This is how most companies you aspire to made it. And if the incumbent is a startup themselves that’s found success, like if you’re Lyft and you see Uber exploding higher, then it’s not even worthwhile to fret about it. You will both have a slice of a gigantic pie and worth more than most executives would define “successful.” If anything, you can copy their success and differentiate in an educated way.</p><p>Sound simple? In reality this is harder than it sounds. “Being the best” takes a certain type of personality and leadership that are anthesis to the mediocrity that corporations tend to breed. Startups also don’t have the luxury that best in class companies do. So, the only way to actually achieve this is via reduced niche focus, fast iterations, long hours, and a strong “being the best” emphasis on your team and spheres of influence.</p><h3>“If you don’t cannibalize yourself, someone else will.” — Steve Jobs</h3><p>Sometimes, a new direction means eating into your old one. That’s actually ok because if you don’t do it, a competitor will string up to offer the product you are not willing. They will end up getting money for that segment and eat into your lunch. So if the market is moving in that direction, you might as well capture all of the value yourself. Did you know that LG offers its exact TV panel to Sony even though they are dead competitors. Samsung produce the chips for the iPhone. iPhones destroyed iPod sales. Tesla builds a cheaper model 3 even if model S drops in sales. Etc, etc, etc.</p><h3>Don’t be in stealth mode</h3><p>In the earliest stage of a startup, founders often are obsessed with competitive pressures and often go to the extremes in their paranoia about it. Most of the time, this is due more to unhealthy insecurity than real harm. I certainly made this mistake. Typical signs of how this manifests is that you hear a founder saying something to the effect of “we are in stealth mode.” They cannot tell others what they do. Why? Because others will steal your idea. But in reality, the founder should be doing the complete opposite.</p><p>If your company is in early stage, bigger fish won’t care what you do, and small fish is struggling enough with their own problems. So this idea that a competitor will crush you with a clone is highly unlikely. They need to feel you are an existential threat before diverting sources and changing roadmaps to address you. So tell the world! Your #1 priority is to get as many people as you possibly can to hear about it and give you feedback on product market fit. Is your product addressing an unmet need that people actually will pay for? You will find that even if you give it all to spread the word and maybe even pay huge sums of money on ads, your product <em>might then have a slight chance</em> at catching on with consumers.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=c2c9d8974234" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Is Your Startup Idea Too Risky? Get Validation]]></title>
            <link>https://nathanaelren.medium.com/is-your-startup-idea-too-risky-part-ii-getting-validation-c27233db657f?source=rss-778d75015485------2</link>
            <guid isPermaLink="false">https://medium.com/p/c27233db657f</guid>
            <category><![CDATA[founders]]></category>
            <category><![CDATA[startup]]></category>
            <category><![CDATA[validation]]></category>
            <category><![CDATA[startup-lessons]]></category>
            <category><![CDATA[entrepreneurship]]></category>
            <dc:creator><![CDATA[Nathanael Ren]]></dc:creator>
            <pubDate>Sun, 06 Jan 2019 20:57:34 GMT</pubDate>
            <atom:updated>2019-07-30T19:55:11.252Z</atom:updated>
            <content:encoded><![CDATA[<h4>Build it and they will not come. Validate your idea first.</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ZOlGsPmFq_IVM_Fd-EbBog.png" /><figcaption>Chris and his bone-density scanner, Pursuit of Happyness</figcaption></figure><p>Chris Gardener, played by Will Smith in the movie <em>Pursuit of Happyness</em>, spent all of his savings on a new type of bone density x-ray machines. The scanners produced a clearer picture. They were supposed to catch on fire. But much to Chris’ surprise, he could not sell past the first 15 units despite all of the smooth-talk he could muster as a salesman. Though the climax of the movie focuses entirely on his eventual breakthrough to become a finance millionaire, its earlier story of failure — the reason behind his purchase of bone-density scanners — has always fascinated me in the lesson it has for entrepreneurs.</p><p>Why did Chris stake his entire savings? Wasn’t it obviously a bad idea? Well… the answer isn’t as simple. The movie positions his venture as a dumb idea from the get-go and primes our negative conclusions by the fact that we know it failed. But hindsight is always 20–20. What was going on in Chris’ mind before he bought those machines? Furthermore, who are the makers of these scanners that spent millions on R&amp;D developing them? Were they all fools? Surely not. There is a reason, a rather prevalent reason. You’ll be surprised how many brilliant young entrepreneurs would sit in a room and convince themselves of, what they would later admit, the dumbest ideas. Even larger companies can fall in this trap (remember Zune by Microsoft?). It’s the <em>pre-validation trap: </em>the build-it-and-they-will-come mentality; the difference between Chris and Jacklyn (see <a href="https://medium.com/@nathanaelren/is-your-startup-idea-too-risky-part-i-a-story-84fb79f3a3b8">part I</a>). Let’s examine in detail.</p><h4>Can’t Prove Your Concept Before Building? Try Harder</h4><p>First a definition: validation in this context is the quickest, cheapest, and <strong>pre-code/production/money</strong>, way of finding out if your idea is also appealing to the people you’re selling to. This is also where most young entrepreneurs ironically struggle with. Mistakes tend to fall into two camps: 1) if the smartest people in the room love the idea, how could the consumer not? 2) a you-can’t-know-until-you’ve-built-it mentality.</p><p><em>Fallacy #1: how could they not love it? So, build it and they will come</em></p><p>The rose-tinted-goggles of a founder’s ego, combined with the allure of millions in the hands of 20 year-olds, can blindside young entrepreneurs. Mixed with a slight paranoia about others stealing their idea, founders would spend weeks holed up in front of a computer, coding up their dreams without telling anyone. The more they fall in love with an idea, the more obvious a need for more features. The reveal has to be perfect and woo their world. Occasionally, they would seek advice from close friends, which consists of humbly asking for feedback, followed by an intense stare. It’s practically stating that any objections would be soul-crushing and an affront to their beliefs, their devotion and even their essence for the past weeks. So, what the founders end up getting is friendly obligations, <em>not</em> <em>validation on value-add or traction</em>. When the product is actually released, s/he is then surprised by the lackadaisical response and a nonexistent word-of-mouth virality that once seemed so certain.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*4o8nXVJtzklvGCxKByz3pw.jpeg" /><figcaption>Taken on Feb 9, 2015. After Buoy’s first full user test at Harvard</figcaption></figure><p>Instead, before building anything. The young entrepreneur should spend 90% of their energy asking potential customers what they’re willing to pay for, <em>prior to building</em>. If nothing, why not? If so, why and how much? Refine, refine and then re-refine your feature set just so you can release the minimum set of features as soon as possible and show it to a non-friendly customer. This is what I mean by getting validation. For example, Jacklyn actually faces a more complicated version of this problem: she has to validate both the supply side of the equation (i.e. drivers’ interest) and the demand side of the equation (i.e. customers). She did by holding poster signs in front of the bus terminal and then asking Uber drivers (see <a href="https://medium.com/@nathanaelren/is-your-startup-idea-too-risky-part-i-a-story-84fb79f3a3b8">part I</a> for details). Chris, on the other hand, pulled out the checkbook before speaking to more than 50 doctors. Also, as counter-intuitive as it may seem, don’t worry whatsoever, that someone will steal your idea. In fact, tell the world! You’ll find getting noticed is a much harder problem even if you tried. Big companies won’t care until you’re big enough to threaten them and small companies have enough of their own problems to mind someone else contrary to all of the hypes around cease-and-decease letters popularized by movies like Social Network. By speaking with customers first, the young entrepreneur will accomplish two things: 1) quickly learn if the idea is worth anything 2) actually start building demand, which is critical for testing traction channels later on (more on this in another post).</p><p><em>Fallacy #2: how can you get validation without the product? You have to build it so people can understand it and want to buy it</em></p><p>After speaking at a panel event at UPenn, I once met a young 22-year-old undergrad who was eager to spend the next 6 months building a profiling tool used at an urgent-care clinic (i.e. think paper forms filled out at a clinic, except on an app). He, Josh, had signed up one friendly clinic but developed no app. Josh was convinced that he needed to spend $10k hiring an app developer so he could roll it out at scale and prove the app’s value. I asked him how was he sure he got the validation needed to build the app, to which he answered that he needed lots of filled-out forms, from an app, before proving it. What about spending $1.5k on 20 undergrads to man the clinic for a month and get 500 paper forms filled?</p><p>Founders often think that they need a product (i.e. website, app, prototype, feature) before they can validate. The thinking typically goes: how can I gauge interest unless I show them my product? But in reality, <em>you’ll think of something if you tried hard enough</em>, even if it means holding a poster in front of the Boston Bus Terminal for 3 hours. The beauty of what Jacklyn did is that she validated real customer demand before offering a single ride. <em>A survey, a drawing or an email chain. Think harder.</em> If the founder really cannot think of a way, beware, the idea might carry too much risk. Chances are, it’s pure-risk, not calculated.</p><p>In the earlier days of Buoy, I used to sit at a cafe with a postcard that said “free coffee” and survey hundreds of strangers what they hated about the current experience of symptom searching. The common answer was that after 30 minutes on Google, people would convince themselves that they have cancer or multiple sclerosis because some rando posted the exact same experience on page 5 of a forum a few years ago. We scraped many features we had assumed were necessary and honed in on the key insights that still give us a relative advantage today.</p><h4>Next Up, Market Sizing</h4><p>Are you taking on too much risk? Getting validation is part of the answer. Another equally important criterium is estimating the potential value of your venture — in business talk, the market size of your venture. This is a much less daunting of a task than most assume. Covered next.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=c27233db657f" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Is Your Startup Idea Too Risky? Part I — A Story]]></title>
            <link>https://nathanaelren.medium.com/is-your-startup-idea-too-risky-part-i-a-story-84fb79f3a3b8?source=rss-778d75015485------2</link>
            <guid isPermaLink="false">https://medium.com/p/84fb79f3a3b8</guid>
            <category><![CDATA[startup-lessons]]></category>
            <category><![CDATA[startup]]></category>
            <category><![CDATA[risk-management]]></category>
            <category><![CDATA[early-stage-startup]]></category>
            <category><![CDATA[founders]]></category>
            <dc:creator><![CDATA[Nathanael Ren]]></dc:creator>
            <pubDate>Tue, 04 Dec 2018 23:13:39 GMT</pubDate>
            <atom:updated>2020-12-29T20:43:08.202Z</atom:updated>
            <content:encoded><![CDATA[<h3>Is Your Startup Idea Too Risky? A Story about 0 to Millions</h3><h4>3 ways to know if you’re taking on too much risk</h4><h4>0 to Millions</h4><p>Jaclyn was riding a Megabus shuttle from Boston to New York when a nagging idea kept her awake in an otherwise boring afternoon. Somewhere in between every stop-and-go in midst of a traffic jam that seemed to stretch forever, she couldn’t help but wonder if 2018, in all its entrepreneurial glory, had only smelly buses to offer. “Where is the Uber for long distance traveling? I bet someone would share a ride with me for $40 instead of this crap,” she repeated to herself.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*z86Z9xsUwaIY_rCbJwPsCg.jpeg" /><figcaption>June 18, 2015. One of Buoy’s earlier all nighters. Cc Justin</figcaption></figure><p>Jaclyn had come from a finance background. Over the course of the last 6 months, as she sat through countless meetings on the same old same old, a dull sense of entrapment slowly ate at her. It was as if she could see her whole life flash before her but in a dreadful way. For someone who, since little, has aspired to do something hands-on that could reach millions of people, she couldn’t connect the dots between what she was doing and where her passions lied. She had wondered about tech startups, at the Zuckerberg styled gold-rush that would allow her a chance to chase her ambitions. But the comfort of a $250K/year private equity offer in the drawer kept those thoughts at bay, only to be resurfaced strangely on occasions like today. Maybe, just maybe, if there’s a will, there’s a way.</p><p>At the Boston South Station Terminal, there were 4 shuttle companies loading 50 people a shuttle, every hour and around the clock. Between just Boston and New York, Jacklyn figured that there are roughly 50 x 24 x 4 x 7 x 52 or 1.7M travelers a year. At $40 average ticket price, these folks spend $68MM a year, not counting other modes of transportation like trains and planes that could also be part of the equation. $68MM between Boston and New York alone, she thought. Lucrative, maybe. Expanding to 50 other routes and taking a 5% market would translate to $170MM a year.<em> Demand and addressable market size: check and large enough.</em></p><p>At such a market size, why aren’t people car-pooling? Well, strictly speaking, that’s not true; they are in fact riding, 24/7 actually — just in private cars with friends and family. What would it take for someone to offer their car and do 800 miles round trip with 8 strangers? $500? Let’s find out. For the next 3 months, on her Uber trips home, Jacklyn would occasionally ask if the driver would be down for her idea. To her surprise, in addition to pleasant conversation, she quickly learned that some are happy to do it for $450 a day, few even willing to go for $200 one way just for the experience of doing a road-trip with new folks and visiting NYC. <em>Supply-side market validation (discussed later): check.</em></p><p>Working 80 hours during the week and then some on her startup idea wasn’t easy. Not much went on until she had shared the idea casually with a consultant friend Helen and decided to join forces - Jaclyn 60%, Helen 40% equity (covering startup equity later). On weekends, they devised a plan to find interested riders, in the easiest and most cost effective manner — standing outside for 3 hours in front of the South Boston Bus Terminal with two posters that stated “$40 car-pooling to NYC in Toyota Highlander.” 15 people came forward. Of course, they didn’t actually do the driving right then and there. But another similar result at Penn State NYC gave them enough confidence to try it. <em>Demand-side market validation: check.</em></p><p>Over the next year, Jaclyn and Helen started off with 2 of their own cars, carrying 4 passengers for 6 trips on a weekend. They then found 10 Uber drivers who were happy to do it as long as the two provided logistics support. Revenue grew to $8k a week when Excel spreadsheets became too cumbersome for keep track. They started scaling using a variety of softwares online and when customers became repeat users, they hired a freelanced app engineer from Upwork to build a simple app. Revenue grew to $25k a week. Before Christmas, a wealthy friend from Jaclyn’s network caught a wind of what they were doing and offered a $1.5MM convertible note at a 15% discount (more on this later). Jaclyn and Helen decided to quit her job and take on the work full time, hiring a logistic manager and 3 full time developers at $100k salary each. By year 2, revenues grew 5% week over week to $110k a week and so the legend goes. In 6 years, the company was bought for $312MM in.</p><h4>Validation, market sizing, and reliable partners</h4><p>I created the above 100% fictitious story to serve as an illustration for the next few parts. Albeit fake, factors that made Jacklyn successful are not far fetched, if not typical of other run-away tech “unicorns.” Either you’ve made it this far because Jaclyn’s story eerily resembles an idea you’ve been ruminating on or it was worthy enough for 5 minutes of your time, I promise to stop here and pick up again next week on the 3 essentials in Jacklyn’s story that I tell young entrepreneurs — validation, market size, and team. Missing any one of these, you are taking on pure risk rather than calculated risk.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=84fb79f3a3b8" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[What Makes Apple a Good Company Name]]></title>
            <link>https://nathanaelren.medium.com/what-makes-apple-a-good-company-name-b613546831e2?source=rss-778d75015485------2</link>
            <guid isPermaLink="false">https://medium.com/p/b613546831e2</guid>
            <category><![CDATA[founders]]></category>
            <category><![CDATA[startup-lessons]]></category>
            <category><![CDATA[entrepreneurship]]></category>
            <category><![CDATA[startup]]></category>
            <dc:creator><![CDATA[Nathanael Ren]]></dc:creator>
            <pubDate>Sun, 21 Oct 2018 19:08:24 GMT</pubDate>
            <atom:updated>2018-10-21T19:08:24.919Z</atom:updated>
            <content:encoded><![CDATA[<p>4 Things to Know about Naming a Company</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*HivpO8G5FoGB0J4iPvptuw.jpeg" /><figcaption>Taken January 7th, 2015. Co-Founder Adam leading a brainstorming session on names</figcaption></figure><p>When you first start thinking about owning a business, giving it a name probably comes early in mind. But what makes a company name stand out in the long run? Why do the most successful tech giants have names like “Apple” or “Amazon,” which are iconic now but seemed totally irrelevant and absurd when they first came to market. These were the questions we asked during the early days of <a href="https://www.buoyhealth.com/">Buoy</a>. In fact, I thought the answer would be easy. I bet if I surveyed 10 random people to come up with a name for a business idea, most of them would have no trouble giving a clever pun followed by a smirk. And so did we. “Qur” we called it — a three-letter play on “cure” that carried the noblest of intentions for healthcare. It had just the right tinge of mystery and a much- needed web 2.0 feel. “Someday, people will say, ‘just Qur it’,” we would joke. But soon it became very apparent that it couldn’t work. We would spend 4 three-hour brainstorm sessions and get the help of an agency to finally nail down a better name. Here are the 4 considerations you need to make to arrive at a good company name. (As always, I speak only for tech startups that rely on web presence.)</p><p>First, be very hesitant to choose a three letter name, unless you’re prepared to spend $100,000+ on a .com domain. All combinations of three-letter URLs have been purchased, by people who know that it’s only a matter of time before an agency or a large corporation would open up their treasure troves to spend whatever necessary to get the .com they need. We are talking about seven figures here. Don’t even try to write them a nice email claiming you’re starting a non-profit and that you’re doing the world good. Everybody has tried that.</p><p>Second, resist the temptation to pick the most obvious name. By obvious, I mean a name that partially describes what the company does. You will run into trademark issues. Let me give you an illustration. Let’s say I’m in the market to sell apples. If I named my company, “Apple,” it would be very hard for me to trademark my brand and defend its uniqueness. Many people in my business will have the word “Apple” somewhere in their name. Thus, when people hear “Apple,” they won’t think of my apples. But if I sold computers, it’s a totally different story. Paradoxically, names that have the strongest trademarks and brand recognizability are those that are remotely tangential, if at all, to the business. Think Apple, Amazon, Tesla, Robinhood, Google, and the list goes on. In fact, we eventually picked Buoy (pronounced as “boo-ie”, rather than somethingMD for this precise reason.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*BDtUHwmKYwWoaiRVgd8-4w.jpeg" /><figcaption>Notice the hidden wave underneath Buoy’s name? Designed by Sam Ayling</figcaption></figure><p>But this doesn’t mean the name should have no relevance at all. Each of the icon names I mentioned above had some sort of metaphoric connection to their business. For Buoy, we loved the fact that buoys serve as a guide for ships lost at sea and can be a verb that means to keep something afloat. We felt that it was a very fitting metaphor for the guidance and uplifting we wish to do for sick users at home.</p><p>Lastly, a good name should pass the bar test, which basically means if you said it to someone at a bar, they should be able to spell it. And if it’s easy to spell, hopefully it can also be verbiafied. On this point, I must admit, Buoy doesn’t pass the bar test. Finding a name is a process of give-and-take and we decided to sacrifice a little here. Though it helps that buoy is an actual English word and strangely enough, because it’s hard to spell, people find it surprisingly sticky once they do get it.</p><p>Hopefully, these four points gave you a better idea of how to pick a company name. If yours already fit all four of the above, give yourself a pat on the back. It’s not an easy feat. But if you haven’t and are tempted to name it something only a computer nerd would like, maybe consider seeking advice from agencies like Hundred Monkeys that specialize in naming. Best of luck!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=b613546831e2" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Introductions]]></title>
            <link>https://nathanaelren.medium.com/introduction-to-my-blog-dd1c774041aa?source=rss-778d75015485------2</link>
            <guid isPermaLink="false">https://medium.com/p/dd1c774041aa</guid>
            <category><![CDATA[nyr]]></category>
            <category><![CDATA[startup]]></category>
            <category><![CDATA[blogger]]></category>
            <category><![CDATA[entrepreneurship]]></category>
            <category><![CDATA[buoy-health]]></category>
            <dc:creator><![CDATA[Nathanael Ren]]></dc:creator>
            <pubDate>Tue, 08 Nov 2016 05:27:04 GMT</pubDate>
            <atom:updated>2018-10-21T19:15:39.574Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*b4TpnoVI_Rk4mwhUtGMC8w.jpeg" /><figcaption>Taken May 6th, 2016 at the Harvard Innovation Lab. One of many user tests conducted during Buoy’s earlier days.</figcaption></figure><p>Since starting Buoy, I’ve found that perceptions of the startup life unfortunately fall into two dichotomous camps: either i) “startup” is synonymous with overnight success stories — think AirBnb, Uber, Mint, etc or ii) it’s just an excuse to play video games all day until finding a new job.</p><p>The reality is neither and hopefully this blog gives you a better idea of entrepreneurship; just in case you want to work for a startup someday or build something you are truly passionate about. I will cover topics such as fund raising, product development, coding, branding, etc but let me know in the comments if there is an specific area you would like me to discuss and I will try to write about it in the upcoming posts. The first entry will be about naming and I will post it after some finishing touches on the blog site. Thanks and looking forward to starting this journey with you!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=dd1c774041aa" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>